feat: tpm (Tmux Plugin Manager) support (#2)
Co-authored-by: Pocco81 <pocco451@gmail.com> Co-authored-by: Lokesh Krishna <lokesh@low-key.me> Co-authored-by: Pocco81 <58336662+Pocco81@users.noreply.github.com> Co-authored-by: vinnyA3 <vincent.aceto@gmail.com> Co-authored-by: winston <hey@winston.sh>
This commit is contained in:
parent
317159f824
commit
97183fc510
10 changed files with 321 additions and 228 deletions
23
catppuccin.tmux
Executable file
23
catppuccin.tmux
Executable file
|
@ -0,0 +1,23 @@
|
|||
#!/usr/bin/env bash
|
||||
CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
||||
|
||||
get-tmux-option() {
|
||||
local option value default
|
||||
option="$1"
|
||||
default="$2"
|
||||
value="$(tmux show-option -gqv "$option")"
|
||||
|
||||
if [ -n "$value" ]; then
|
||||
echo "$value"
|
||||
else
|
||||
echo "$default"
|
||||
fi
|
||||
}
|
||||
|
||||
main() {
|
||||
local theme
|
||||
theme="$(get-tmux-option "@catppuccin_flavour" "mocha")"
|
||||
tmux run -b "$CURRENT_DIR/catppuccin-${theme}.tmuxtheme"
|
||||
}
|
||||
|
||||
main "$@"
|
Loading…
Add table
Add a link
Reference in a new issue