ci: update flake use gh app to push
This commit is contained in:
parent
4e9907c39a
commit
ca28d39ec4
1 changed files with 12 additions and 4 deletions
16
.github/workflows/update-flake-inputs.yml
vendored
16
.github/workflows/update-flake-inputs.yml
vendored
|
|
@ -3,17 +3,24 @@ name: Update flake inputs
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: '0 0 * * 0'
|
- cron: "0 0 * * 0"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
update-flake:
|
update-flake:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- name: Generate app token
|
||||||
|
id: app-token
|
||||||
|
uses: actions/create-github-app-token@v3
|
||||||
|
with:
|
||||||
|
app-id: ${{ secrets.APP_ID }}
|
||||||
|
private-key: ${{ secrets.APP_PRIVATE_KEY }}
|
||||||
|
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
token: ${{ steps.app-token.outputs.token }}
|
||||||
|
persist-credentials: false
|
||||||
|
|
||||||
- name: Install Nix
|
- name: Install Nix
|
||||||
uses: nixbuild/nix-quick-install-action@v31
|
uses: nixbuild/nix-quick-install-action@v31
|
||||||
|
|
@ -80,6 +87,7 @@ jobs:
|
||||||
if: steps.check.outputs.modified == 'true'
|
if: steps.check.outputs.modified == 'true'
|
||||||
uses: EndBug/add-and-commit@v9
|
uses: EndBug/add-and-commit@v9
|
||||||
with:
|
with:
|
||||||
|
token: ${{ steps.app-token.outputs.token }}
|
||||||
add: flake.lock
|
add: flake.lock
|
||||||
default_author: github_actions
|
default_author: github_actions
|
||||||
message: "[CI] chore: update flake"
|
message: "[CI] chore: update flake"
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue