Skip to content

Commit 8147790

Browse files
committed
ci/update: always cd to the root of the flake
Allows running the script from a sub-directory, e.g. cd ci nix-build -A update result/bin/update
1 parent d142524 commit 8147790

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

ci/update.nix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ writeShellApplication {
3131
update_args+=( "--commit-lock-file" )
3232
fi
3333
34+
# Ensure we run at the root of the flake
35+
cd "$(git rev-parse --show-toplevel)"
36+
3437
currentCommit() {
3538
git show --no-patch --format=%h
3639
}

0 commit comments

Comments
 (0)