Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Run action on node v20 #16

Merged
merged 3 commits into from
Sep 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,17 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
- name: Build action on node v16
uses: actions/setup-node@v3
with:
node-version: 16
- run: npm install
- run: npm run package
- run: npm run test
- name: Test action on node v20
uses: actions/setup-node@v3
with:
node-version: 20
- id: default
uses: ./
- name: Test current commit hash is used by default
Expand Down
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ A GitHub Action for using the long and short [hash of a commit][git/commits]
— with an optional prefix.

```
prompt/actions-commit-hash@v2
prompt/actions-commit-hash@v3
```

:package: [Automatic Release Packaging](#automatic-release-packaging) is used by
Expand Down Expand Up @@ -41,10 +41,10 @@ jobs:
steps:
steps:
- id: commit
uses: prompt/actions-commit-hash@v2
- uses: docker/setup-buildx-action@v1
uses: prompt/actions-commit-hash@v3
- uses: docker/setup-buildx-action@v3
- name: Build image for commit
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: ${{ steps.commit.outputs.short }}
Expand All @@ -71,13 +71,13 @@ jobs:
steps:
steps:
- id: commit
uses: prompt/actions-commit-hash@v2
uses: prompt/actions-commit-hash@v3
with:
commit: "${{ github.event.workflow_run.head_sha }}"
prefix: "sha-"
- uses: docker/setup-buildx-action@v1
- uses: docker/setup-buildx-action@v3
- name: Build image for commit
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: ${{ steps.commit.outputs.short }}
Expand All @@ -90,8 +90,8 @@ Any reference to this Action in a Workflow must use a [tag][tags] (mutable) or
the commit hash of a tag (immutable).

```yaml
✅ uses: prompt/actions-commit-hash@v2
✅ uses: prompt/actions-commit-hash@v2.0.0
✅ uses: prompt/actions-commit-hash@v3
✅ uses: prompt/actions-commit-hash@v3.0.0
✅ uses: prompt/actions-commit-hash@01d19a83c242e1851c9aa6cf9625092ecd095d09
❌ uses: prompt/actions-commit-hash@main
```
Expand Down
2 changes: 1 addition & 1 deletion action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,5 +20,5 @@ outputs:
hash:
description: "Original, 40-character SHA-1 hash received as `commit` input"
runs:
using: "node16"
using: "node20"
main: "dist/index.js"
Loading