Skip to content

Merge pull request #482 from InjectiveLabs/dev #23

Merge pull request #482 from InjectiveLabs/dev

Merge pull request #482 from InjectiveLabs/dev #23

Workflow file for this run

name: Publish stable
on:
push:
branches:
- master
jobs:
publish:
if: true
runs-on: ubuntu-latest
permissions: write-all
steps:
- name: 'Checkout' # Download code from the repository
uses: actions/checkout@v2 # Public action
with:
fetch-depth: 0 # Checkout all branches and tags
persist-credentials: false
- name: 'Use NodeJS 18' # Setup node using version 14
uses: actions/setup-node@v2 # Public action
with:
node-version: '18.17.0'
- name: 'Setup [email protected]'
run: yarn global add [email protected] --ignore-engines
- name: Set up Git user
run: |
git config user.name "${{ github.actor }}"
git config user.email "${{ github.actor }}@users.noreply.github.com"
- name: Build dependencies
run: |
lerna clean --yes
node etc/bootstrapEnv
yarn install --ignore-engines
yarn build
- name: Setup npm
run: |
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc
npm whoami
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Version and publish
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
lerna version patch --conventional-commits --conventional-graduate --force-git-tag --yes
lerna publish from-git --force-git-tag --dist-tag latest --yes --summary-file
env:

Check failure on line 56 in .github/workflows/stable.yaml

View workflow run for this annotation

GitHub Actions / Publish stable

Invalid workflow file

The workflow is not valid. .github/workflows/stable.yaml (Line: 56, Col: 9): 'env' is already defined
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
- name: 'Broadcast published versions on Slack'
run: node etc/slack --api=$SLACK_API --actor=$GIT_ACTOR --commit-message=$GIT_LATEST_COMMIT_MESSAGE
env:
GIT_ACTOR: ${{ github.actor }}
SLACK_API: ${{ secrets.SLACK_API }}
GIT_LATEST_COMMIT_MESSAGE: ${{ github.event.head_commit.message }}
- name: Merge master -> dev
uses: devmasx/merge-branch@master
with:
type: now
from_branch: master
target_branch: dev
github_token: ${{ secrets.GH_TOKEN }}