diff options
author | Cole Mickens <cole.mickens@gmail.com> | 2018-10-24 06:59:24 -0700 |
---|---|---|
committer | Cole Mickens <cole.mickens@gmail.com> | 2018-10-24 06:59:24 -0700 |
commit | f2f68817f8f70dee2eb8cb946b356cb89c8be6d4 (patch) | |
tree | 8b893cca2cf90c83dcae06fe81aaab30ec9fa4c8 /update.sh | |
parent | 74d575d207419d3c641bf29a35ceff6927681b4f (diff) |
update.sh: auto-upload to cache after build
Diffstat (limited to 'update.sh')
-rwxr-xr-x | update.sh | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -27,6 +27,7 @@ EOF } # attr_name repo_owner repo_name repo_rev +if [[ -z "${SKIP:-}" ]]; then update "wlroots" "swaywm" "wlroots" "master" update "sway-beta" "swaywm" "sway" "master" update "slurp" "emersion" "slurp" "master" @@ -34,11 +35,16 @@ update "grim" "emersion" "grim" "master" update "wlstream" "atomnuker" "wlstream" "master" update "waybar" "Alexays" "waybar" "master" update "nixpkgs" "nixos" "nixpkgs-channels" "nixos-unstable" +fi -nix-build --no-out-link build.nix +results="$(nix-build --no-out-link build.nix)" +readarray -t out <<< "$(echo "${results}")" d="$(date -Iseconds)" m="(.+)" t="<!--update-->" sed -i -E "s/${t}${m}${t}/${t}${d}${t}/g" README.md +if [[ -e "/etc/nixcfg/utils/azure/nix-copy-azure.sh" ]]; then + "/etc/nixcfg/utils/azure/nix-copy-azure.sh" "${out[@]}" +fi |