ci: add the ability to run without updating

This commit is contained in:
Aaron Bieber 2023-02-02 10:38:40 -07:00
parent cba85185c0
commit a6e80a224f
No known key found for this signature in database
2 changed files with 13 additions and 7 deletions

18
ci
View File

@ -23,9 +23,15 @@ if [ $can_sign != 1 ]; then
fi
git pull || handle_pull_fail
git checkout -b "${ci_branch}" || handle_co_fail
nix flake update --commit-lock-file || handle_update_fail
nix flake check || handle_check_fail
git checkout main || handle_co_fail
git merge "${ci_branch}" || handle_merge_fail
git push || handle_push_fail
if [ "${1}" = "update" ]; then
git checkout -b "${ci_branch}" || handle_co_fail
nix flake update --commit-lock-file || handle_update_fail
nix flake check || handle_check_fail
git checkout main || handle_co_fail
git merge "${ci_branch}" || handle_merge_fail
git push || handle_push_fail
else
nix flake check || handle_check_fail
fi

View File

@ -7,7 +7,7 @@ let
];
jobs = [{
name = "xin-ci";
script = "cd ~/src/xin && ./ci";
script = "cd ~/src/xin && ./ci update";
startAt = "daily";
path = [ ];
}];