Skip to content

Commit

Permalink
Merge pull request #6 from emilymclean/chore/update-actions
Browse files Browse the repository at this point in the history
Update actions to avoid deprecation
  • Loading branch information
emilymclean authored Nov 16, 2024
2 parents 3d4aaa0 + afce722 commit 03134c7
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 28 deletions.
51 changes: 27 additions & 24 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@ jobs:
version: ${{ steps.gitversion.outputs.semVer }}
steps:
- name: Check out code
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Install GitVersion
uses: gittools/actions/gitversion/setup@v0.9.6
uses: gittools/actions/gitversion/setup@v3.0.0
with:
versionSpec: '5.x'
- name: Use GitVersion
id: gitversion # step id used as reference for output values
uses: gittools/actions/gitversion/execute@v0.9.6
uses: gittools/actions/gitversion/execute@v3.0.0
with:
useConfigFile: true
configFilePath: ./gitversion.yml
Expand All @@ -35,19 +35,19 @@ jobs:
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Lowercase Repository
run: |
echo "REPOSITORY_LC=${REPOSITORY,,}" >>${GITHUB_ENV}
env:
REPOSITORY: '${{ github.repository }}'
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
uses: docker/setup-buildx-action@v3
- name: Docker meta
id: meta
uses: docker/metadata-action@v4
uses: docker/metadata-action@v5
with:
images: |
ghcr.io/${{ env.REPOSITORY_LC }}
Expand All @@ -60,13 +60,13 @@ jobs:
type=semver,pattern={{major}}
type=sha
- name: Log in to the Container registry
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
uses: docker/login-action@v3
with:
registry: https://ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push Docker image
uses: docker/build-push-action@v4
uses: docker/build-push-action@v6
with:
context: .
platforms: linux/amd64
Expand All @@ -87,7 +87,7 @@ jobs:
contents: write
steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Lowercase Repository
run: |
echo "REPOSITORY_LC=${REPOSITORY,,}" >>${GITHUB_ENV}
Expand All @@ -102,7 +102,7 @@ jobs:
vars: |
image: docker://ghcr.io/${{ env.REPOSITORY_LC }}:${{ needs.version.outputs.version }}
- name: Update README.md
uses: recih/[email protected]
uses: emilymclean/[email protected]
env:
ACTION_REPO: ${{ github.repository }}
ACTION_VERSION: ${{ needs.version.outputs.version }}
Expand All @@ -126,18 +126,19 @@ jobs:
if: github.event_name != 'pull_request'
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Create Release
id: create_release
uses: actions/create-release@v1
uses: actions/checkout@v4
- name: Create tag for release
uses: rickstaa/action-create-tag@v1
with:
tag: v${{ needs.version.outputs.version }}
- id: create_release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ needs.version.outputs.version }}
release_name: Release ${{ needs.version.outputs.version }}
draft: false
name: Release ${{ needs.version.outputs.version }}
prerelease: ${{ github.ref == 'refs/heads/develop' }}
commitish: ${{ needs.update-image.outputs.commit_hash }}
release-other:
runs-on: ubuntu-latest
needs:
Expand All @@ -149,14 +150,16 @@ jobs:
if: github.event_name != 'pull_request' && github.ref != 'refs/heads/main'
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Create Release
id: create_release
uses: actions/create-release@v1
uses: actions/checkout@v4
- name: Create tag for release
uses: rickstaa/action-create-tag@v1
with:
tag: v${{ needs.version.outputs.version }}
- id: create_release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
uses: softprops/action-gh-release@v2
with:
tag_name: v${{ needs.version.outputs.version }}
release_name: Release ${{ needs.version.outputs.version }}
draft: false
name: Release ${{ needs.version.outputs.version }}
prerelease: ${{ github.ref == 'refs/heads/develop' }}
8 changes: 4 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- uses: actions/checkout@v2
uses: actions/checkout@v4
- uses: actions/checkout@v4
with:
repository: FPGAwars/icezum
ref: dbad423670419b82018bf6e33c418fc35558c1be
Expand All @@ -37,9 +37,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
uses: actions/checkout@v4
- name: Update README.md
uses: recih/[email protected]
uses: emilymclean/[email protected]
env:
ACTION_REPO: ${{ github.repository }}
ACTION_VERSION: v1.0.0
Expand Down

0 comments on commit 03134c7

Please sign in to comment.