summaryrefslogtreecommitdiff
path: root/lib/common.nix
diff options
context:
space:
mode:
authorBen Sima <ben@bsima.me>2019-08-27 15:13:55 -0700
committerBen Sima <ben@bsima.me>2019-08-27 15:13:55 -0700
commitdb6d02e3a42d4264883a82d8f11a49848b77bd7f (patch)
tree83caac3c624f2fca7fb6d7e3bedc127fbd0528a3 /lib/common.nix
parent9489a7b13e74bddcca14f90c4041d007fbeb5961 (diff)
undo remove homedir
Diffstat (limited to 'lib/common.nix')
-rw-r--r--lib/common.nix21
1 files changed, 11 insertions, 10 deletions
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
}