summaryrefslogtreecommitdiffstats
path: root/tv/2configs
diff options
context:
space:
mode:
Diffstat (limited to 'tv/2configs')
-rw-r--r--tv/2configs/bash/default.nix22
-rw-r--r--tv/2configs/default.nix5
-rw-r--r--tv/2configs/xserver/default.nix13
3 files changed, 24 insertions, 16 deletions
diff --git a/tv/2configs/bash/default.nix b/tv/2configs/bash/default.nix
index b75ad8bf..d7673931 100644
--- a/tv/2configs/bash/default.nix
+++ b/tv/2configs/bash/default.nix
@@ -13,6 +13,20 @@ with import <stockholm/lib>;
shopt -s histappend histreedit histverify
shopt -s no_empty_cmd_completion
complete -d cd
+
+ case $UID in
+ ${shell.escape (toString config.krebs.users.tv.uid)})
+ if test ''${SHLVL-1} = 1; then
+ case ''${XMONAD_SPAWN_WORKSPACE-} in
+ stockholm)
+ cd ~/stockholm
+ ;;
+ esac
+ fi
+
+ export NIX_PATH="stockholm=$HOME/stockholm:$NIX_PATH"
+ ;;
+ esac
'';
promptInit = /* sh */ ''
case $UID in
@@ -32,14 +46,6 @@ with import <stockholm/lib>;
if test -n "$SSH_AGENT_PID"; then
PS1="ssh-agent[$SSH_AGENT_PID] $PS1"
fi
-
- if test ''${SHLVL-1} = 1; then
- case ''${XMONAD_SPAWN_WORKSPACE-} in
- stockholm)
- cd ~/stockholm
- ;;
- esac
- fi
'';
};
}
diff --git a/tv/2configs/default.nix b/tv/2configs/default.nix
index d9ddc90d..484a337b 100644
--- a/tv/2configs/default.nix
+++ b/tv/2configs/default.nix
@@ -87,11 +87,6 @@ with import <stockholm/lib>;
export SYSTEM="$1"
exec nix-shell -I stockholm="$PWD" --run 'deploy --system="$SYSTEM"'
'';
- reload = "systemctl reload";
- restart = "systemctl restart";
- start = "systemctl start";
- status = "systemctl status";
- stop = "systemctl stop";
};
environment.variables = {
diff --git a/tv/2configs/xserver/default.nix b/tv/2configs/xserver/default.nix
index a44ece8b..22c94f7b 100644
--- a/tv/2configs/xserver/default.nix
+++ b/tv/2configs/xserver/default.nix
@@ -57,7 +57,9 @@ in {
systemd.services.display-manager.enable = false;
- systemd.services.xmonad = {
+ systemd.services.xmonad = let
+ xmonad = "${pkgs.haskellPackages.xmonad-tv}/bin/xmonad";
+ in {
wantedBy = [ "graphical.target" ];
requires = [ "xserver.service" ];
environment = {
@@ -93,6 +95,11 @@ in {
"za" "zh" "zj" "zs"
]);
};
+ path = [
+ pkgs.fzmenu
+ pkgs.pulseaudioLight.out
+ pkgs.rxvt_unicode
+ ];
serviceConfig = {
SyslogIdentifier = "xmonad";
ExecStartPre = "${pkgs.coreutils}/bin/mkdir -p ${toString [
@@ -100,8 +107,8 @@ in {
"\${XMONAD_CONFIG_DIR}"
"\${XMONAD_DATA_DIR}"
]}";
- ExecStart = "${pkgs.xmonad-tv}/bin/xmonad-${currentSystem}";
- ExecStop = "${pkgs.xmonad-tv}/bin/xmonad-${currentSystem} --shutdown";
+ ExecStart = "@${xmonad} xmonad-${currentSystem} ";
+ ExecStop = "@${xmonad} xmonad-${currentSystem} --shutdown";
User = cfg.user.name;
WorkingDirectory = cfg.user.home;
};