File tree Expand file tree Collapse file tree 3 files changed +40
-4
lines changed
Expand file tree Collapse file tree 3 files changed +40
-4
lines changed Original file line number Diff line number Diff line change 1+ name : Publish to Blockware Public NPM
2+ on :
3+ push :
4+ branches :
5+ - master
6+ jobs :
7+ build :
8+ runs-on : ubuntu-latest
9+ steps :
10+ - uses : actions/checkout@v2
11+ - uses : actions/setup-node@v3
12+ with :
13+ node-version : 18
14+ registry-url : https://registry.npmjs.org/
15+
16+ - id : ' auth'
17+ uses : ' google-github-actions/auth@v1'
18+ with :
19+ credentials_json : ' ${{ secrets.GCP_ARTIFACTORY_SERVICE_ACCOUNT }}'
20+
21+ - name : ' Set up Cloud SDK'
22+ uses : ' google-github-actions/setup-gcloud@v1'
23+ with :
24+ project_id : ${{ secrets.GCP_PROJECT_ID }}
25+ - run : echo '@blockware:registry=${{ secrets.GCP_ARTIFACT_NPM_URL }}' > .npmrc
26+ - run : npm install
27+ - run : npx google-artifactregistry-auth .npmrc
28+ - run : npm publish --registry ${{ secrets.GCP_ARTIFACT_NPM_URL }}
Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ class RestClient {
4949 break ;
5050 case 'body' :
5151 opts . body = JSON . stringify ( requestArgument . value ) ;
52- opts . headers [ 'Content-Type ' ] = 'application/json' ;
52+ opts . headers [ 'content-type ' ] = 'application/json' ;
5353 break ;
5454 case 'query' :
5555 query . push ( encodeURIComponent ( requestArgument . name ) + '=' + encodeURIComponent ( requestArgument . value ) ) ;
@@ -58,7 +58,7 @@ class RestClient {
5858 } ) ;
5959
6060 if ( query . length > 0 ) {
61- opts . url += '?' + query . join ( '&' ) ;
61+ url += '?' + query . join ( '&' ) ;
6262 }
6363
6464 const result = await fetch ( url , opts ) ;
You can’t perform that action at this time.
0 commit comments