Compare commits

..

1 Commits

Author SHA1 Message Date
87451bfcfe Add auto-update workflow 2025-10-11 19:11:19 +02:00
2 changed files with 31 additions and 25 deletions

View File

@@ -15,9 +15,8 @@ jobs:
uses: actions/checkout@v4
- name: Set git bot info
shell: nu {0}
run: |
git config user.email "noreply@notadev.net"
run: >-
git config user.email "noreply@notadev.net" &&
git config user.name "Update bot"
- name: Login to Gitea
@@ -41,18 +40,28 @@ jobs:
run: nix flake update
- name: Create new commit
run: |
git checkout -b update-lockfile
git add flake.lock
git commit -m "Update flake.lock"
run: >-
git checkout -b update-lockfile &&
git add flake.lock &&
git commit -m "Update flake.lock" &&
git push origin update-lockfile
- name: Create PR
shell: bash
run: |
cd "${{ env.GITHUB_WORKSPACE }}"
echo "$PWD"
export XDG_CONFIG_HOME="$PWD"
env:
SERVER_URL: tea.notadev.net
SERVER_TOKEN: ${{ secrets.token }}
SERVER_USER: ${{ secrets.user }}
SERVER_PASSWORD: ${{ secrets.password }}
run: >-
cd "${{ env.GITHUB_WORKSPACE }}" &&
echo "$PWD" &&
export GITEA_SERVER_URL="$SERVER_URL" &&
export GITEA_SERVER_TOKEN="$SERVER_TOKEN" &&
export GITEA_SERVER_USER="$SERVER_USER" &&
export GITEA_SERVER_PASSWORD="$SERVER_PASSWORD" &&
export XDG_CONFIG_HOME="$PWD" &&
export XDG_CONFIG_HOME="$PWD" &&
tea pr create --title "Update flake.lock"
- name: Merge PR
@@ -64,15 +73,12 @@ jobs:
let $index = tea pr list --fields "index,head" --output csv
| from csv
| where head =~ update-lockfile
| get index
| $in.0
tea pr merge $index --style merge
| select index
| first 1
tea pr merge --style merge
- name: Delete branch
shell: nu {0}
shell: bash
run: |
cd "${{ env.GITHUB_WORKSPACE }}"
echo $env.PWD
git checkout main
git branch -D update-lockfile
git branch -d update-lockfile
git push origin :update-lockfile

12
flake.lock generated
View File

@@ -20,11 +20,11 @@
},
"nixpkgs-master": {
"locked": {
"lastModified": 1770508249,
"narHash": "sha256-3ahhMTAMoK9KLjmmWAfdC9nVQgGoMACkCsJ99VyAOA8=",
"lastModified": 1755684980,
"narHash": "sha256-PdWvn30jHwPCGfcTV2Uu22yo4hpGsoWMDHjpAjVeqx4=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "a5cf8d3e5e416aadc5eea9b019823e9b61673abc",
"rev": "263c40ffdf668f4e7d7d3fc4d3318af7fee1d6f9",
"type": "github"
},
"original": {
@@ -36,11 +36,11 @@
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1770197578,
"narHash": "sha256-AYqlWrX09+HvGs8zM6ebZ1pwUqjkfpnv8mewYwAo+iM=",
"lastModified": 1755615617,
"narHash": "sha256-HMwfAJBdrr8wXAkbGhtcby1zGFvs+StOp19xNsbqdOg=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "00c21e4c93d963c50d4c0c89bfa84ed6e0694df2",
"rev": "20075955deac2583bb12f07151c2df830ef346b4",
"type": "github"
},
"original": {