diff options
Diffstat (limited to 'overlays/patches/emacs/overlay/.ci/cron')
-rwxr-xr-x | overlays/patches/emacs/overlay/.ci/cron | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/overlays/patches/emacs/overlay/.ci/cron b/overlays/patches/emacs/overlay/.ci/cron new file mode 100755 index 000000000000..3887f42ad48f --- /dev/null +++ b/overlays/patches/emacs/overlay/.ci/cron @@ -0,0 +1,19 @@ +#!/bin/sh +# Note: This script is executed from git root +export NIX_PATH=nixpkgs=https://github.com/NixOS/nixpkgs/archive/nixos-unstable.tar.gz + +if [ $CI_PIPELINE_SOURCE != "schedule" ] && [ $CI_PIPELINE_SOURCE != "web" ]; then + echo "Only scheduled or manual jobs will run, consider successful" + echo "TODO: This should probably test something meaningful like instantiantion of all derivations" + exit 0 +fi + +mkdir -p ~/.ssh +nix-shell -p openssh --run 'ssh-keyscan github.com >> ~/.ssh/known_hosts' + +nix-shell -p git --run 'git config --global user.name "emacs-overlay"' +nix-shell -p git --run 'git config --global user.email "emacs-overlay@nix-community"' +nix-shell -p git --run 'git remote set-url --push origin git@github.com:nix-community/emacs-overlay.git' + +./update +./.ci/push |