From ab0ef5c987b7f179725032d920ac75b66aa194e1 Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Fri, 31 Mar 2023 16:55:42 -0700 Subject: home/sway: start sway and ssh-agent properly I only need to run sway and the ssh-agent on a workstation (desktop or laptop). Start these two processes when the window manager starts. --- home/shell/zsh/default.nix | 8 -------- home/shell/zsh/ssh-agent.zsh | 3 --- home/shell/zsh/sway.zsh | 3 --- 3 files changed, 14 deletions(-) delete mode 100644 home/shell/zsh/ssh-agent.zsh delete mode 100644 home/shell/zsh/sway.zsh (limited to 'home/shell') diff --git a/home/shell/zsh/default.nix b/home/shell/zsh/default.nix index 6bf11ab..3734fc3 100644 --- a/home/shell/zsh/default.nix +++ b/home/shell/zsh/default.nix @@ -36,15 +36,7 @@ in defaultKeymap = "emacs"; - # the order matters for sway.zsh: I want to load it first - # to start the session if I log on a machine where it's - # available. - # it can't be loaded with `initExtraFirst` because the session - # variables from home-manager are not set yet otherwise (and I - # need them for things like firefox or emacs). initExtra = lib.concatMapStrings builtins.readFile [ - ./ssh-agent.zsh - ./sway.zsh ./completion-style.zsh ./options.zsh ./prompt.zsh diff --git a/home/shell/zsh/ssh-agent.zsh b/home/shell/zsh/ssh-agent.zsh deleted file mode 100644 index 1e5d81c..0000000 --- a/home/shell/zsh/ssh-agent.zsh +++ /dev/null @@ -1,3 +0,0 @@ -if [ $(ps ax | grep "[s]sh-agent" | wc -l) -eq 0 ] ; then - eval $(ssh-agent -s -a ${XDG_RUNTIME_DIR}/ssh-agent.sock) > /dev/null -fi diff --git a/home/shell/zsh/sway.zsh b/home/shell/zsh/sway.zsh deleted file mode 100644 index 69d5103..0000000 --- a/home/shell/zsh/sway.zsh +++ /dev/null @@ -1,3 +0,0 @@ -if [ -z $DISPLAY ] && [ "$(tty)" = "/dev/tty1" ]; then - exec sway -fi -- cgit 1.4.1