autoupdate
This commit is contained in:
parent
138772ab74
commit
269cc6d3d8
9
.envrc
9
.envrc
|
@ -1,5 +1,14 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
git config --local core.hooksPath "$PWD"/.githooks
|
git config --local core.hooksPath "$PWD"/.githooks
|
||||||
|
|
||||||
|
test -d .direnv || mkdir -p .direnv
|
||||||
|
now="$(date +%Y-%m-%d)"
|
||||||
|
if ! test -s .direnv/pull-date || test "$now" != "$(cat .direnv/pull-date)"; then
|
||||||
|
git pull --rebase --autostash
|
||||||
|
nix flake update
|
||||||
|
echo "$now" > .direnv/pull-date
|
||||||
|
fi
|
||||||
|
|
||||||
if ! command -v nixos-rebuild >/dev/null; then
|
if ! command -v nixos-rebuild >/dev/null; then
|
||||||
use nix
|
use nix
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
result
|
result
|
||||||
/configuration.nix
|
/configuration.nix
|
||||||
/hardware-configuration.nix
|
/hardware-configuration.nix
|
||||||
|
.direnv
|
||||||
|
|
Loading…
Reference in New Issue