mirror of
https://codeberg.org/leana8959/.files.git
synced 2025-12-06 06:39:14 +00:00
packages/tmux-sessionizer: remove tmux-register-session
We already use the builtin leader-l binding, no need to keep this.
This commit is contained in:
parent
eac1c86fe8
commit
29c4ca1a81
1 changed files with 0 additions and 20 deletions
|
|
@ -8,24 +8,6 @@
|
|||
symlinkJoin,
|
||||
}:
|
||||
let
|
||||
tmux-register-session = writeShellApplication {
|
||||
name = "__tmux-register-session";
|
||||
runtimeInputs = [ tmux ];
|
||||
text = ''
|
||||
last=/tmp/TMUX_LAST
|
||||
|
||||
# bail if tmux not running
|
||||
if ! pgrep tmux >/dev/null 2>&1; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
this="$(tmux display-message -p '#S')"
|
||||
if [ ! -f "$last" ] || [ "$(cat "$last")" != "$this" ]; then
|
||||
echo "$this" >"$last"
|
||||
fi
|
||||
'';
|
||||
};
|
||||
|
||||
tmux-maybe-create = writeShellApplication {
|
||||
name = "__tmux-maybe-create";
|
||||
runtimeInputs = [
|
||||
|
|
@ -94,7 +76,6 @@ let
|
|||
esac
|
||||
|
||||
# effects
|
||||
${lib.getExe tmux-register-session} || :
|
||||
${lib.getExe tmux-maybe-create} "$session_name" "$selected"
|
||||
${lib.getExe tmux-attach-or-switch} "$session_name"
|
||||
'';
|
||||
|
|
@ -103,7 +84,6 @@ in
|
|||
symlinkJoin {
|
||||
name = "tmux-sessionizer";
|
||||
paths = [
|
||||
tmux-register-session
|
||||
tmux-maybe-create
|
||||
tmux-attach-or-switch
|
||||
tmux-sessionizer
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue