style: rename github steps
Some checks failed
Check / check (push) Failing after 0s

This commit is contained in:
trev 2025-05-17 03:08:52 -04:00
parent 4f9dee1e27
commit e20156a2de
3 changed files with 13 additions and 19 deletions

View File

@ -20,5 +20,4 @@ jobs:
with: with:
token: "${{ secrets.CACHIX_AUTH_TOKEN }}" token: "${{ secrets.CACHIX_AUTH_TOKEN }}"
- name: Check - run: nix flake check
run: nix flake check

View File

@ -18,8 +18,7 @@ jobs:
with: with:
token: "${{ secrets.CACHIX_AUTH_TOKEN }}" token: "${{ secrets.CACHIX_AUTH_TOKEN }}"
- name: check - run: nix flake check
run: nix flake check
release: release:
runs-on: ubuntu-latest runs-on: ubuntu-latest
@ -30,8 +29,7 @@ jobs:
with: with:
token: "${{ secrets.CACHIX_AUTH_TOKEN }}" token: "${{ secrets.CACHIX_AUTH_TOKEN }}"
- name: build - run: >
run: >
nix build nix build
.#trevstack-linux-amd64 .#trevstack-linux-amd64
.#trevstack-linux-arm64 .#trevstack-linux-arm64
@ -40,8 +38,7 @@ jobs:
.#trevstack-darwin-amd64 .#trevstack-darwin-amd64
.#trevstack-darwin-arm64 .#trevstack-darwin-arm64
- name: release - uses: softprops/action-gh-release@v2
uses: softprops/action-gh-release@v2
with: with:
generate_release_notes: true generate_release_notes: true
files: |- files: |-
@ -56,7 +53,7 @@ jobs:
with: with:
token: "${{ secrets.CACHIX_AUTH_TOKEN }}" token: "${{ secrets.CACHIX_AUTH_TOKEN }}"
- name: set env - name: Set env
run: | run: |
TAG=${{ github.ref_name }} TAG=${{ github.ref_name }}
VERSION=${TAG#v} VERSION=${TAG#v}
@ -65,20 +62,19 @@ jobs:
echo "VERSION=${VERSION}" >> $GITHUB_ENV echo "VERSION=${VERSION}" >> $GITHUB_ENV
echo "REGISTRY=${REGISTRY}" >> $GITHUB_ENV echo "REGISTRY=${REGISTRY}" >> $GITHUB_ENV
- name: login to github container registry - uses: docker/login-action@v3
uses: docker/login-action@v3
with: with:
registry: ghcr.io registry: ghcr.io
username: ${{ github.actor }} username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }} password: ${{ secrets.GITHUB_TOKEN }}
- name: build & load images - name: Build & load images
run: | run: |
nix build .#trevstack-linux-amd64-image && ./result | docker load nix build .#trevstack-linux-amd64-image && ./result | docker load
nix build .#trevstack-linux-arm64-image && ./result | docker load nix build .#trevstack-linux-arm64-image && ./result | docker load
nix build .#trevstack-linux-arm-image && ./result | docker load nix build .#trevstack-linux-arm-image && ./result | docker load
- name: push images - name: Push images
run: | run: |
docker image tag trevstack:$VERSION-amd64 $REGISTRY/$GITHUB_REPOSITORY:$VERSION-amd64 docker image tag trevstack:$VERSION-amd64 $REGISTRY/$GITHUB_REPOSITORY:$VERSION-amd64
docker push $REGISTRY/$GITHUB_REPOSITORY:$VERSION-amd64 docker push $REGISTRY/$GITHUB_REPOSITORY:$VERSION-amd64
@ -89,7 +85,7 @@ jobs:
docker image tag trevstack:$VERSION-arm $REGISTRY/$GITHUB_REPOSITORY:$VERSION-arm docker image tag trevstack:$VERSION-arm $REGISTRY/$GITHUB_REPOSITORY:$VERSION-arm
docker push $REGISTRY/$GITHUB_REPOSITORY:$VERSION-arm docker push $REGISTRY/$GITHUB_REPOSITORY:$VERSION-arm
- name: push manifest - name: Push manifest
run: | run: |
docker manifest create $REGISTRY/$GITHUB_REPOSITORY:$VERSION \ docker manifest create $REGISTRY/$GITHUB_REPOSITORY:$VERSION \
$REGISTRY/$GITHUB_REPOSITORY:$VERSION-amd64 \ $REGISTRY/$GITHUB_REPOSITORY:$VERSION-amd64 \

View File

@ -19,15 +19,14 @@ jobs:
token: "${{ secrets.CACHIX_AUTH_TOKEN }}" token: "${{ secrets.CACHIX_AUTH_TOKEN }}"
# https://github.com/actions/checkout/issues/13 # https://github.com/actions/checkout/issues/13
- name: set git config - name: Set git config
run: | run: |
git config user.name "github-actions[bot]" git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com" git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
- name: update - run: nix run .#update
run: nix run .#update
- name: create pull request - name: Create pull request
id: cpr id: cpr
uses: peter-evans/create-pull-request@v7 uses: peter-evans/create-pull-request@v7
with: with:
@ -35,7 +34,7 @@ jobs:
title: update title: update
body: automatic update body: automatic update
- name: enable automerge - name: Enable automerge
run: gh pr merge --merge --auto "${{ steps.cpr.outputs.pull-request-number }}" run: gh pr merge --merge --auto "${{ steps.cpr.outputs.pull-request-number }}"
env: env:
GH_TOKEN: ${{ secrets.PAT }} GH_TOKEN: ${{ secrets.PAT }}