Skip to content

Commit

Permalink
Merge pull request #29 from sammygriffiths/fix/update-actions
Browse files Browse the repository at this point in the history
Update versions in github actions scripts
  • Loading branch information
sammygriffiths authored Oct 5, 2024
2 parents 277809b + 2690a3a commit a9b3984
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
26 changes: 13 additions & 13 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ jobs:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 12
node-version: 'latest'
- run: npm ci
- run: npm test
get_tag:
Expand All @@ -23,13 +23,13 @@ jobs:
tag: ${{ steps.get_tag.outputs.tag }}
tag_exists: ${{ steps.check_tag.outputs.exists }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Get tag
id: get_tag
run: |
echo "##[set-output name=tag;]$(git log -1 --pretty=%B | tr '\n' ' ' | sed -E 's/.*(v[0-9]+\.[0-9]+\.[0-9]+).*/\1/')"
- name: Check if tag exists
uses: mukunku/tag-exists-action@v1.0.0
uses: mukunku/tag-exists-action@v1.6.0
id: check_tag
with:
tag: ${{ steps.get_tag.outputs.tag }}
Expand All @@ -41,24 +41,24 @@ jobs:
runs-on: ubuntu-latest
needs: [get_tag, test]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Create Release
uses: actions/create-release@v1
uses: elgohr/Github-Release-Action@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ needs.get_tag.outputs.tag }}
release_name: ${{ needs.get_tag.outputs.tag }}
tag: ${{ needs.get_tag.outputs.tag }}
title: ${{ needs.get_tag.outputs.tag }}
deploy:
name: Deploy
runs-on: ubuntu-latest
needs: tag
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v2-beta
uses: actions/setup-node@v4
with:
node-version: '12'
node-version: 'latest'
registry-url: https://registry.npmjs.org/
- name: Install NPM Packages
run: npm ci
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/bump-npm-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,14 @@ jobs:
if: "!contains( github.ref, 'release' )"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Get version
id: get_version
run: echo "##[set-output name=version;]$(echo $GITHUB_HEAD_REF | sed -e "s/^release\///")"
- name: Update npm version
run: npm version ${{ steps.get_version.outputs.version }} --git-tag-version=false --allow-same-version
- name: Commit changes
uses: EndBug/add-and-commit@v5
uses: EndBug/add-and-commit@v9
with:
author_name: github-actions
author_email: github-actions@github.com
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ jobs:
name: Run tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: '12'
node-version: 'latest'
- name: Install dependencies
run: npm ci
- name: Run tests
Expand Down

0 comments on commit a9b3984

Please sign in to comment.