From db6d02e3a42d4264883a82d8f11a49848b77bd7f Mon Sep 17 00:00:00 2001 From: Ben Sima Date: Tue, 27 Aug 2019 15:13:55 -0700 Subject: undo remove homedir --- lib/common.nix | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to 'lib/common.nix') diff --git a/lib/common.nix b/lib/common.nix index f2fb65d..474a363 100644 --- a/lib/common.nix +++ b/lib/common.nix @@ -3,6 +3,7 @@ let locale = "en_US.UTF-8"; gpgid = "D09299626FA78AF8"; + homedir = builtins.getEnv "HOME"; in { home = { @@ -12,9 +13,9 @@ in EDITOR = "emacsclient"; LANG = locale; LANGUAGE = locale; - PATH = "\$HOME/bin:\$HOME/.local/bin:$PATH"; + PATH = "${homedir}/bin:${homedir}/.local/bin:$PATH"; PAGER = "less"; - LEDGER_FILE = "\$HOME/.hledger.journal"; + LEDGER_FILE = "${homedir}/.hledger.journal"; XTERM_LOCALE = locale; LOCALE_ARCHIVE = "${pkgs.glibcLocales}/lib/locale/locale-archive"; }; @@ -34,7 +35,7 @@ in programs = { home-manager = { enable = true; - path = "\$HOME/cfg/home-manager"; + path = "${homedir}/cfg/home-manager"; }; tmux = { @@ -57,37 +58,37 @@ in "sabten" = { hostname = "142.93.81.26"; user = "root"; - identityFile = [ "\$HOME/.ssh/id_rsa" ]; + identityFile = [ "${homedir}/.ssh/id_rsa" ]; identitiesOnly = true; }; "simatime.com" = { hostname = "simatime.com"; user = "git"; - identityFile = [ "\$HOME/.ssh/id_rsa" ]; + identityFile = [ "${homedir}/.ssh/id_rsa" ]; identitiesOnly = true; }; gh = { hostname = "github.com"; user = "git"; - identityFile = [ "\$HOME/.ssh/id_rsa" ]; + identityFile = [ "${homedir}/.ssh/id_rsa" ]; identitiesOnly = true; }; lithium = { hostname = "69.181.254.154"; user = "ben"; - identityFile = [ "\$HOME/.ssh/hijuj-zupip" ]; + identityFile = [ "${homedir}/.ssh/hijuj-zupip" ]; identitiesOnly = true; }; nutin-madaj = { hostname = "159.89.128.69"; user = "root"; - identityFile = [ "\$HOME/.ssh/biz-deploy" ]; + identityFile = [ "${homedir}/.ssh/biz-deploy" ]; identitiesOnly = true; }; hikuj-zupip = { hostname = "69.181.254.154"; user = "root"; - identityFile = [ "\$HOME/.ssh/biz-deploy" ]; + identityFile = [ "${homedir}/.ssh/biz-deploy" ]; identitiesOnly = true; }; }; @@ -120,7 +121,7 @@ in DIR=~/.nix-profile/etc/profile.d [[ -f "$DIR/nix.sh" ]] && . "$DIR/nix.sh" [[ -f "$DIR/hm-session-vars.sh" ]] && . "$DIR/hm-session-vars.sh" - [[ -f "$HOME/.bashrc.local" ]] && . "$HOME/.bashrc.local" + [[ -f "${homedir}/.bashrc.local" ]] && . "${homedir}/.bashrc.local" function cd() { builtin cd "$@" && ls } -- cgit v1.2.3