From 80815faa135f67390f18e944a164d0ba7d0eb5c8 Mon Sep 17 00:00:00 2001 From: Javier De La Fuente Sales Date: Thu, 22 Feb 2024 14:11:29 +0100 Subject: [PATCH] feat: setting up publish --- .github/workflows/publish.yaml | 30 ++++++++++++++++++++++++++++++ package.json | 2 +- 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/publish.yaml diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml new file mode 100644 index 000000000..14f3e9e20 --- /dev/null +++ b/.github/workflows/publish.yaml @@ -0,0 +1,30 @@ +name: Deploy Spanner + +on: + push: + branches: ['main'] + pull_request: + branches: ['main'] + +jobs: + build: + name: Deployment + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + - name: Setup + uses: actions/setup-node@v3 + with: + node-version: '14' + registry-url: 'https://npm.pkg.github.com' + scope: '@streamyard' + - name: Install Dependencies + run: npm ci + - name: Build Package + run: npm run prepare + - name: Publish + if: ${{ github.ref == 'refs/heads/main' }} + run: npm publish --access restricted ./build/src + env: + NPM_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/package.json b/package.json index a6b66fed6..a5ec1b101 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@google-cloud/spanner", "description": "Cloud Spanner Client Library for Node.js", - "version": "7.3.0", + "version": "7.3.0-1", "license": "Apache-2.0", "author": "Google Inc.", "engines": {