Skip to content

Commit

Permalink
Fix git author error while pushing new versions (#6)
Browse files Browse the repository at this point in the history
  • Loading branch information
tobyjsullivan committed Apr 15, 2022
1 parent e8842ce commit 2ff8a0f
Showing 1 changed file with 7 additions and 24 deletions.
31 changes: 7 additions & 24 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
run: yarn test:eslint-plugin-axios

update-versions:
name: 'Update package versions'
name: 'Publish to NPM'

needs: ['prettier', 'eslint', 'test-eslint-plugin-axios']

Expand All @@ -82,6 +82,12 @@ jobs:
- uses: actions/checkout@v3
with:
ref: main
# Token with higher permissions is required for lerna to push versions
token: ${{ secrets.GITHUB_TOKEN }}

# Fetch all history for all tags and branches in this job because lerna needs it
- run: |
git fetch --prune --unshallow
- name: Setup Node.js
uses: actions/setup-node@v3
Expand All @@ -96,29 +102,6 @@ jobs:
- name: Update Versions
run: npx lerna version --conventional-commits --exact --yes

publish:
name: 'Publish to NPM'

needs: ['update-versions']

if: "github.ref == 'refs/heads/main' && !contains(github.event.head_commit.message, 'skip ci')"

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
with:
ref: main

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 14
cache: 'yarn'

- name: Installing dependencies
run: yarn install --frozen-lockfile

- name: Publish to NPM
run: npx lerna publish --yes
env:
Expand Down

0 comments on commit 2ff8a0f

Please sign in to comment.