Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# name: Publish Release | |
# on: | |
# release: | |
# types: [released] | |
# jobs: | |
# build: | |
# runs-on: ubuntu-latest | |
# strategy: | |
# matrix: | |
# node-version: [18] | |
# steps: | |
# - uses: actions/checkout@v4 | |
# with: | |
# token: ${{ secrets.PACKAGE_SECRET }} | |
# - name: Check cache | |
# id: cache | |
# uses: actions/cache@v1 | |
# with: | |
# path: packages/sdk/node_modules | |
# key: ${{ runner.os }}-node-${{ hashFiles('**/yarn.lock') }}-0 | |
# restore-keys: | | |
# ${{ runner.os }}-node- | |
# - name: Use Node ${{ matrix.node-version }} | |
# uses: actions/setup-node@v2 | |
# with: | |
# node-version: ${{ matrix.node-version }} | |
# registry-url: "https://registry.npmjs.org" | |
# - name: install dependencies | |
# run: yarn install | |
# - name: run linting | |
# run: yarn ci-lint | |
# - name: run tests | |
# run: yarn cover | |
# - name: run readmeUpdater | |
# run: yarn make-badges | |
# - name: build code | |
# run: yarn build | |
# - name: bump version | |
# uses: phips28/gh-action-bump-version@master | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# NODE_AUTH_TOKEN: ${{ secrets.PACKAGE_SECRET }} | |
# with: | |
# version-type: 'patch' | |
# skip-commit: "true" | |
# skip-tag: "true" | |
# - name: execute local js script | |
# run: node ./.github/scripts/replicate-version.js | |
# - name: publish sdk build | |
# run: | | |
# # Get the full reference of the release | |
# ref=${{ github.ref }} | |
# # Remove the refs/tags/ prefix | |
# tag=${ref#refs/tags/} | |
# stripped_tag=${tag%-*} | |
# node cicd.js sdk,connectors yarn publish --tag $stripped_tag --tag latest | |
# env: | |
# NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }} | |
# - name: execute commit script | |
# run: node ./.github/scripts/commit.js | |
# - name: get new npm version | |
# id: package-version | |
# uses: martinbeentjes/npm-get-version-action@master | |
# - name: copy file branch | |
# run: | | |
# path=packages/sdk/upload/latest | |
# versionpath=packages/sdk/upload/${{ github.event.release.name }} | |
# mkdir -p ${path%"/merge"} | |
# cp -R packages/sdk/_bundles/* ${path%"/merge"} | |
# mkdir -p ${versionpath%"/merge"} | |
# cp -R packages/sdk/_bundles/* ${versionpath%"/merge"} | |
# - name: Copy to Azure Blob Storage | |
# uses: azure/CLI@v1 | |
# with: | |
# inlineScript: | | |
# az storage blob upload-batch -d sdk -s packages/sdk/upload/ --connection-string "${{ secrets.AZURE_CDN_STUDIO_PRD_CONNECTION_STRING }}" --overwrite true | |
# - name: prepare for actions upload | |
# run: | | |
# node cicd.js actions node scripts/prepare-release.mjs | |
# - name: Copy to Azure Blob Storage (Actions) | |
# uses: azure/CLI@v1 | |
# with: | |
# inlineScript: | | |
# az storage blob upload-batch -d sdk -s packages/actions/cdn/ --connection-string "${{ secrets.AZURE_CDN_STUDIO_PRD_CONNECTION_STRING }}" --overwrite true | |
# bump: | |
# runs-on: ubuntu-latest | |
# strategy: | |
# matrix: | |
# node-version: [18] | |
# needs: build | |
# steps: | |
# - name: bump version | |
# uses: phips28/gh-action-bump-version@master | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# NODE_AUTH_TOKEN: ${{ secrets.PACKAGE_SECRET }} | |
# with: | |
# version-type: 'preminor' | |
# skip-commit: "true" | |
# skip-tag: "true" | |
# - name: execute local js script | |
# run: node ./.github/scripts/replicate-version.js | |
# - name: execute commit script | |
# run: node ./.github/scripts/commit.js |