change to saved working dir with mod+shift+enter

This commit is contained in:
Vladan Popovic 2024-10-01 22:21:39 +02:00
parent 9547f92da7
commit 5963529e1b
2 changed files with 1 additions and 3 deletions

View file

@ -33,9 +33,6 @@ export PS1="${Yellow}\d \A ${Off}${Green}\u@\h: ${Off}\w ${Red}\$(parse_branch g
hash fzf 2>/dev/null && eval "$(fzf --bash)" hash fzf 2>/dev/null && eval "$(fzf --bash)"
export FZF_DEFAULT_OPTS='--border=horizontal --info=inline --no-reverse --height=50%' export FZF_DEFAULT_OPTS='--border=horizontal --info=inline --no-reverse --height=50%'
# Change to saved working dir.
[[ -f "${HOME}/.cwd" ]] && cd "$(< ${HOME}/.cwd)"
# Use gpg-agent as ssh agent (and get a nice graphical prompt). # Use gpg-agent as ssh agent (and get a nice graphical prompt).
unset SSH_AGENT_PID unset SSH_AGENT_PID
if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then

View file

@ -4,6 +4,7 @@
# #
# start a terminal # start a terminal
bindsym $mod+Return exec $term bindsym $mod+Return exec $term
bindsym $mod+Shift+Return exec $term --working-directory=$(cat ~/.cwd || $HOME)
# kill focused window # kill focused window
bindsym $mod+Shift+q kill bindsym $mod+Shift+q kill