remoteenv cleanup
This commit is contained in:
parent
ac56f68f3a
commit
8ee842d89a
10
.envrc
10
.envrc
@ -15,15 +15,11 @@ if ! test -s .direnv/pull-date || test "$now" != "$(cat .direnv/pull-date)"; the
|
||||
echo "$now" > .direnv/pull-date
|
||||
fi
|
||||
|
||||
if command -v nixos-rebuild >/dev/null; then
|
||||
use flake .#nixos-rebuild-nom
|
||||
elif ! command -v nixos-rebuild >/dev/null; then
|
||||
use flake .#non-nixos
|
||||
fi
|
||||
use flake .#envrc
|
||||
|
||||
if test -s .remote.toml; then
|
||||
if ! command -v remote-init >/dev/null; then
|
||||
use flake .#remote
|
||||
if ! command -v remote-init >/dev/null || ! command -v tomlq >/dev/null; then
|
||||
use flake .#envrc-remote
|
||||
fi
|
||||
echo
|
||||
echo "Current remote: $(remote-host)"
|
||||
|
@ -1,3 +1,3 @@
|
||||
#!/usr/bin/env bash
|
||||
eval "$(nix print-dev-env .#nixos-rebuild-nom)"
|
||||
eval "$(nix print-dev-env .#remoteenv)"
|
||||
echo Entered $(hostname --fqdn)
|
||||
|
@ -17,10 +17,9 @@
|
||||
|
||||
# TODO: somehow make these private repos optional (a lazy fetch would be nice)
|
||||
pbsds-papers.url = "git+ssh://git@github.com/pbsds/papers.git";
|
||||
#pbsds-papers.flake = false;
|
||||
|
||||
# temporary stuff i want to use
|
||||
# TODO: can i fetch a subset of files if these? ^
|
||||
# TODO: can i fetch a subset of files of these?
|
||||
pr-polaris14.url = "github:pbsds/nixpkgs/polaris-14";
|
||||
pr-remote-exec.url = "github:pbsds/nixpkgs/remote-exec-init";
|
||||
};
|
||||
@ -118,15 +117,15 @@
|
||||
'';
|
||||
mkShell = packages: pkgs.mkShell { inherit packages; };
|
||||
in {
|
||||
nixos-rebuild-nom = mkShell [
|
||||
remoteenv = mkShell [
|
||||
nixos-rebuild-nom
|
||||
];
|
||||
non-nixos = mkShell [
|
||||
envrc = mkShell [
|
||||
nixos-rebuild-nom
|
||||
pkgs.home-manager
|
||||
pkgs.nix-output-monitor
|
||||
];
|
||||
remote = mkShell [
|
||||
encrc-remote = mkShell [
|
||||
remote-exec
|
||||
pkgs.yq
|
||||
];
|
||||
|
Loading…
Reference in New Issue
Block a user