Compare commits
2 commits
67f511bd96
...
f677f6a545
Author | SHA1 | Date | |
---|---|---|---|
|
f677f6a545 | ||
|
32e5c173ed |
|
@ -1,7 +1,6 @@
|
|||
[bonsai]
|
||||
source = imaps://brk%40bonsai.cool:panda@mail.bonsai.cool
|
||||
outgoing = smtps://brk%40bonsai.cool:panda@mail.bonsai.cool
|
||||
source = maildir://~/mail/bonsai/
|
||||
outgoing = /home/brk/bin/msmtpq
|
||||
default = INBOX
|
||||
from = Jovan Djokic-Sumarac <brk@bonsai.cool>
|
||||
cache-headers = true
|
||||
copy-to = Sent
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
# title=foot
|
||||
# locked-title=no
|
||||
|
||||
font = 0xProto Nerd Font:size=12,Noto Sans CJK JP:size=12
|
||||
font = 0xProto Nerd Font:size=12,FiraCode Nerd Font:size=12,Noto Sans CJK JP:size=12
|
||||
|
||||
# font-bold=<bold variant of regular font>
|
||||
# font-italic=<italic variant of regular font>
|
||||
|
|
|
@ -1,31 +0,0 @@
|
|||
|
||||
decoration {
|
||||
rounding=12
|
||||
multisample_edges=1
|
||||
|
||||
active_opacity=1
|
||||
inactive_opacity=1
|
||||
|
||||
blur=1
|
||||
blur_size=3
|
||||
blur_passes=1
|
||||
blur_new_optimizations = true
|
||||
|
||||
drop_shadow=true
|
||||
shadow_range=20
|
||||
shadow_render_power = 3
|
||||
}
|
||||
|
||||
|
||||
bezier=slow,0,0.85,0.3,1
|
||||
bezier=overshot,0.7,0.6,0.1,1.1
|
||||
|
||||
animations {
|
||||
enabled=1
|
||||
|
||||
bezier=overshot,0.13,0.99,0.29,1.1
|
||||
animation=windows,1,4,overshot,slide
|
||||
animation=border,1,10,default
|
||||
animation=fade,1,10,default
|
||||
animation=workspaces,1,6,overshot,slide
|
||||
}
|
|
@ -1,44 +0,0 @@
|
|||
|
||||
input {
|
||||
kb_layout=us,rs
|
||||
kb_variant=,yz
|
||||
kb_options=caps:escape,grp:menu_toggle
|
||||
|
||||
follow_mouse=1
|
||||
|
||||
numlock_by_default=1
|
||||
repeat_rate=50
|
||||
repeat_delay=300
|
||||
}
|
||||
|
||||
general {
|
||||
sensitivity=2
|
||||
|
||||
gaps_in=10
|
||||
gaps_out=20
|
||||
|
||||
layout=master
|
||||
|
||||
col.active_border = rgba(ee111166) rgba(11ee1166) rgba(1111ee66) 45deg
|
||||
col.inactive_border = rgba(00000000)
|
||||
border_size=3
|
||||
no_border_on_floating=true
|
||||
}
|
||||
|
||||
|
||||
|
||||
gestures {
|
||||
workspace_swipe=true
|
||||
workspace_swipe_fingers=3
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
misc {
|
||||
enable_swallow=1
|
||||
swallow_regex=^(alacritty)$
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -1,67 +0,0 @@
|
|||
# some nice mouse binds
|
||||
bindm=SUPER,mouse:272,movewindow
|
||||
bindm=SUPER,mouse:273,resizewindow
|
||||
|
||||
# example binds
|
||||
bind=SUPER,Return,exec,footclient
|
||||
bind=SUPER,W,exec,chromium --ignore-gpu-blocklist --enable-gpu-rasterization --enable-zero-copy --ozone-platform-hint=auto
|
||||
bind=SUPER,Escape,exec,powermenu-v
|
||||
bind=SUPER,Q,killactive,
|
||||
bind=SUPER,Space,fullscreen,1
|
||||
bind=SUPERSHIFT,Space,fullscreen,0
|
||||
bind=SUPERSHIFT,Q,exit,
|
||||
bind=SUPER,E,exec,footclient --title nmtuiterm -e nmtuidelay
|
||||
bind=SUPER,R,exec,footclient --title lfterm -e lf "$(cat .cache/lfdir)"
|
||||
bind=SUPER,F,togglefloating,
|
||||
bind=SUPER,D,exec,tmenu
|
||||
bind=SUPERSHIFT,D,exec,tmenu -d
|
||||
|
||||
|
||||
bind=SUPER,left,movefocus,l
|
||||
bind=SUPER,right,movefocus,r
|
||||
bind=SUPER,up,movefocus,u
|
||||
bind=SUPER,down,movefocus,d
|
||||
|
||||
bind=SUPER,1,workspace,1
|
||||
bind=SUPER,2,workspace,2
|
||||
bind=SUPER,3,workspace,3
|
||||
bind=SUPER,4,workspace,4
|
||||
bind=SUPER,5,workspace,5
|
||||
bind=SUPER,6,workspace,6
|
||||
|
||||
bind=SUPERSHIFT,1,movetoworkspace,1
|
||||
bind=SUPERSHIFT,2,movetoworkspace,2
|
||||
bind=SUPERSHIFT,3,movetoworkspace,3
|
||||
bind=SUPERSHIFT,4,movetoworkspace,4
|
||||
bind=SUPERSHIFT,5,movetoworkspace,5
|
||||
bind=SUPERSHIFT,6,movetoworkspace,6
|
||||
|
||||
bind=SUPER,mouse_down,workspace,e+1
|
||||
bind=SUPER,mouse_up,workspace,e-1
|
||||
|
||||
bind=SUPERSHIFT,R,forcerendererreload
|
||||
|
||||
|
||||
|
||||
bind=SUPER,S,togglespecialworkspace
|
||||
bind=SUPERSHIFT,S,movetoworkspace,special
|
||||
|
||||
|
||||
|
||||
|
||||
bind=SUPER,Tab,cyclenext
|
||||
|
||||
|
||||
|
||||
bind=,F4,exec,pamixer --toggle-mute
|
||||
bind=,F2,exec,volctl --down
|
||||
bind=,F3,exec,volctl --up
|
||||
bind=,F7,exec,lightctl --down
|
||||
bind=,F8,exec,lightctl --up
|
||||
|
||||
|
||||
|
||||
bind=,XF86AudioPlay,exec,playerctl play-pause
|
||||
bind=,XF86Audiostop,exec,playerctl stop
|
||||
bind=,XF86AudioNext,exec,playerctl next
|
||||
bind=,XF86AudioPrev,exec,playerctl previous
|
|
@ -1,3 +0,0 @@
|
|||
monitor=eDP-1,1920x1080@60,1920x0,1
|
||||
monitor=HDMI-A-1,1920x1080@165,0x0,1
|
||||
monitor=HDMI-A-1,transform,0
|
|
@ -1,6 +0,0 @@
|
|||
windowrule=float,title:^(pulsemixerterm)$
|
||||
windowrule=float,title:^(nmtuiterm)$
|
||||
windowrule=workspace special silent,title:^(scratchpad)$
|
||||
windowrule=workspace 2,class:^(chromium)$
|
||||
windowrule=workspace 6,class:^(ferdium)$
|
||||
windowrule=workspace 4,class:^(org.pwmt.zathura)$
|
|
@ -1,25 +0,0 @@
|
|||
|
||||
# WALLPAPER
|
||||
|
||||
#exec-once=mpvpaper -vs -o "no-audio loop --speed=0.4" eDP-1 ~/.config/wall.webm
|
||||
#exec-once=swaybg -m fill -i hdd/wallpapers/berk/berserker_armor_devouring.png
|
||||
|
||||
|
||||
# STUFF
|
||||
|
||||
exec-once=/usr/bin/polkit-dumb-agent
|
||||
exec-once=hyprpaper
|
||||
exec-once=salut
|
||||
exec-once=mkfifo /tmp/wobpipe
|
||||
exec-once=tail -f /tmp/wobpipe | wob
|
||||
|
||||
exec-once=waybar
|
||||
exec-once=tuf-tray
|
||||
|
||||
exec-once=foot --server
|
||||
# WM go brrr?
|
||||
|
||||
exec-once=systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
|
||||
|
||||
exec-once=rgb-borders
|
176
.config/hypr/hhh
176
.config/hypr/hhh
|
@ -1,176 +0,0 @@
|
|||
# See https://wiki.hyprland.org/Configuring/Monitors/
|
||||
monitor = HDMI-A-1, 2560x1440@75, 0x0, 1,# transform,1
|
||||
monitor = DP-1, 1920x1080@165, 2560x0, 1
|
||||
monitor = eDP-1, 1920x1080@120, 3480x0, 1
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||
|
||||
# Execute your favorite apps at launch
|
||||
# exec-once = waybar & hyprpaper & firefox
|
||||
|
||||
# Source a file (multi-file configs)
|
||||
# source = ~/.config/hypr/myColors.conf
|
||||
|
||||
# Set programs that you use
|
||||
$terminal = kitty
|
||||
$fileManager = dolphin
|
||||
$menu = wofi --show drun
|
||||
|
||||
# Some default env vars.
|
||||
env = XCURSOR_SIZE,24
|
||||
env = QT_QPA_PLATFORMTHEME,qt5ct # change to qt6ct if you have that
|
||||
|
||||
# For all categories, see https://wiki.hyprland.org/Configuring/Variables/
|
||||
input {
|
||||
kb_layout = us
|
||||
kb_variant =
|
||||
kb_model =
|
||||
kb_options =
|
||||
kb_rules =
|
||||
|
||||
follow_mouse = 1
|
||||
|
||||
touchpad {
|
||||
natural_scroll = no
|
||||
}
|
||||
|
||||
sensitivity = 0 # -1.0 to 1.0, 0 means no modification.
|
||||
}
|
||||
|
||||
general {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
|
||||
gaps_in = 5
|
||||
gaps_out = 20
|
||||
border_size = 2
|
||||
col.active_border = rgba(33ccffee) rgba(00ff99ee) 45deg
|
||||
col.inactive_border = rgba(595959aa)
|
||||
|
||||
layout = dwindle
|
||||
|
||||
# Please see https://wiki.hyprland.org/Configuring/Tearing/ before you turn this on
|
||||
allow_tearing = false
|
||||
}
|
||||
|
||||
decoration {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
|
||||
rounding = 10
|
||||
|
||||
blur {
|
||||
enabled = true
|
||||
size = 3
|
||||
passes = 1
|
||||
}
|
||||
|
||||
drop_shadow = yes
|
||||
shadow_range = 4
|
||||
shadow_render_power = 3
|
||||
col.shadow = rgba(1a1a1aee)
|
||||
}
|
||||
|
||||
animations {
|
||||
enabled = yes
|
||||
|
||||
# Some default animations, see https://wiki.hyprland.org/Configuring/Animations/ for more
|
||||
|
||||
bezier = myBezier, 0.05, 0.9, 0.1, 1.05
|
||||
|
||||
animation = windows, 1, 7, myBezier
|
||||
animation = windowsOut, 1, 7, default, popin 80%
|
||||
animation = border, 1, 10, default
|
||||
animation = borderangle, 1, 8, default
|
||||
animation = fade, 1, 7, default
|
||||
animation = workspaces, 1, 6, default
|
||||
}
|
||||
|
||||
dwindle {
|
||||
# See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more
|
||||
pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below
|
||||
preserve_split = yes # you probably want this
|
||||
}
|
||||
|
||||
master {
|
||||
# See https://wiki.hyprland.org/Configuring/Master-Layout/ for more
|
||||
new_is_master = true
|
||||
}
|
||||
|
||||
gestures {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
workspace_swipe = off
|
||||
}
|
||||
|
||||
misc {
|
||||
# See https://wiki.hyprland.org/Configuring/Variables/ for more
|
||||
force_default_wallpaper = -1 # Set to 0 or 1 to disable the anime mascot wallpapers
|
||||
}
|
||||
|
||||
# Example per-device config
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more
|
||||
device {
|
||||
name = epic-mouse-v1
|
||||
sensitivity = -0.5
|
||||
}
|
||||
|
||||
# Example windowrule v1
|
||||
# windowrule = float, ^(kitty)$
|
||||
# Example windowrule v2
|
||||
# windowrulev2 = float,class:^(kitty)$,title:^(kitty)$
|
||||
# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more
|
||||
windowrulev2 = suppressevent maximize, class:.* # You'll probably like this.
|
||||
|
||||
|
||||
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
|
||||
$mainMod = SUPER
|
||||
|
||||
# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more
|
||||
bind = $mainMod, Q, exec, $terminal
|
||||
bind = $mainMod, C, killactive,
|
||||
bind = $mainMod, M, exit,
|
||||
bind = $mainMod, E, exec, $fileManager
|
||||
bind = $mainMod, V, togglefloating,
|
||||
bind = $mainMod, R, exec, $menu
|
||||
bind = $mainMod, P, pseudo, # dwindle
|
||||
bind = $mainMod, J, togglesplit, # dwindle
|
||||
|
||||
# Move focus with mainMod + arrow keys
|
||||
bind = $mainMod, left, movefocus, l
|
||||
bind = $mainMod, right, movefocus, r
|
||||
bind = $mainMod, up, movefocus, u
|
||||
bind = $mainMod, down, movefocus, d
|
||||
|
||||
# Switch workspaces with mainMod + [0-9]
|
||||
bind = $mainMod, 1, workspace, 1
|
||||
bind = $mainMod, 2, workspace, 2
|
||||
bind = $mainMod, 3, workspace, 3
|
||||
bind = $mainMod, 4, workspace, 4
|
||||
bind = $mainMod, 5, workspace, 5
|
||||
bind = $mainMod, 6, workspace, 6
|
||||
bind = $mainMod, 7, workspace, 7
|
||||
bind = $mainMod, 8, workspace, 8
|
||||
bind = $mainMod, 9, workspace, 9
|
||||
bind = $mainMod, 0, workspace, 10
|
||||
|
||||
# Move active window to a workspace with mainMod + SHIFT + [0-9]
|
||||
bind = $mainMod SHIFT, 1, movetoworkspace, 1
|
||||
bind = $mainMod SHIFT, 2, movetoworkspace, 2
|
||||
bind = $mainMod SHIFT, 3, movetoworkspace, 3
|
||||
bind = $mainMod SHIFT, 4, movetoworkspace, 4
|
||||
bind = $mainMod SHIFT, 5, movetoworkspace, 5
|
||||
bind = $mainMod SHIFT, 6, movetoworkspace, 6
|
||||
bind = $mainMod SHIFT, 7, movetoworkspace, 7
|
||||
bind = $mainMod SHIFT, 8, movetoworkspace, 8
|
||||
bind = $mainMod SHIFT, 9, movetoworkspace, 9
|
||||
bind = $mainMod SHIFT, 0, movetoworkspace, 10
|
||||
|
||||
# Example special workspace (scratchpad)
|
||||
bind = $mainMod, S, togglespecialworkspace, magic
|
||||
bind = $mainMod SHIFT, S, movetoworkspace, special:magic
|
||||
|
||||
# Scroll through existing workspaces with mainMod + scroll
|
||||
bind = $mainMod, mouse_down, workspace, e+1
|
||||
bind = $mainMod, mouse_up, workspace, e-1
|
||||
|
||||
# Move/resize windows with mainMod + LMB/RMB and dragging
|
||||
bindm = $mainMod, mouse:272, movewindow
|
||||
bindm = $mainMod, mouse:273, resizewindow
|
|
@ -8,7 +8,7 @@ general {
|
|||
|
||||
listener {
|
||||
timeout = 300 # in seconds
|
||||
on-timeout = hyprlock # command to run when timeout has passed
|
||||
on-timeout = syslock # command to run when timeout has passed
|
||||
on-resume = notify-send "Welcome back!" # command to run when activity is detected after timeout has fired.
|
||||
}
|
||||
|
||||
|
|
|
@ -4,28 +4,26 @@
|
|||
# who cares? \ o Y o /
|
||||
# put the \ \__ __/ /
|
||||
# tranny on the '.__'-'__.'
|
||||
# choping block '''
|
||||
# chopping block '''
|
||||
|
||||
|
||||
source = ~/.config/hypr/monitors.conf
|
||||
source = ~/.config/hypr/general.conf
|
||||
source = ~/.config/hypr/decoration.conf
|
||||
source = ~/.config/hypr/rules.conf
|
||||
source = ~/.config/hypr/keybinds.conf
|
||||
source = ~/.config/hypr/workspaces.conf
|
||||
source = ~/.config/hypr/env.conf
|
||||
source = ~/.config/hypr/slices/monitors.conf
|
||||
source = ~/.config/hypr/slices/general.conf
|
||||
source = ~/.config/hypr/slices/decoration.conf
|
||||
source = ~/.config/hypr/slices/rules.conf
|
||||
source = ~/.config/hypr/slices/keybinds.conf
|
||||
source = ~/.config/hypr/slices/workspaces.conf
|
||||
source = ~/.config/hypr/slices/env.conf
|
||||
|
||||
|
||||
# STARTUP
|
||||
|
||||
exec-once = dunst
|
||||
exec-once = foot --server
|
||||
exec-once = avizo-service
|
||||
exec-once = avizo-client
|
||||
exec-once = syshud
|
||||
exec-once = waybar
|
||||
exec-once = hyprpaper
|
||||
exec-once = ~/bin/xdg-portal-hyprland
|
||||
exec-once = wl-paste --watch cliphist store
|
||||
exec-once = hypridle
|
||||
# exec-once = wl-paste --watch cliphist store
|
||||
exec-once = wayland-pipewire-idle-inhibit
|
||||
exec-once = hyprsunset -t 5000
|
||||
exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
exec-once = ~/bin/xdg-portal-hyprland
|
||||
|
|
|
@ -1,7 +1,5 @@
|
|||
preload = /home/brk/pics/guts_stars.jpg
|
||||
preload = /home/brk/pics/lll/japan_sunset.png
|
||||
|
||||
wallpaper = eDP-1,/home/brk/pics/guts_stars.jpg
|
||||
wallpaper = DP-1,/home/brk/pics/guts_stars.jpg
|
||||
wallpaper = HDMI-A-1,/home/brk/pics/guts_stars.jpg
|
||||
wallpaper = ,/home/brk/pics/lll/japan_sunset.png
|
||||
|
||||
ipc = off
|
||||
|
|
|
@ -1,23 +0,0 @@
|
|||
# MONITOR LAYOUT
|
||||
#
|
||||
# monitor = HDMI-A-1, 2560x1440@75, 0x0, 1.0, bitdepth, 10
|
||||
# monitor = DP-1, disabled
|
||||
# monitor = eDP-1, disabled
|
||||
#
|
||||
|
||||
# monitor=HDMI-A-1,2560x1440@75,1920x0,1.0,bitdepth,10
|
||||
# monitor=eDP-1,1920x1080@120,0x0,1.0,bitdepth,10
|
||||
# monitor=DP-1,1920x1080@165,4480x0,1.0,bitdepth,10
|
||||
|
||||
# monitor = eDP-1, 1920x1080@120, 0x0, 1.0, bitdepth, 10
|
||||
# monitor = HDMI-A-1, 2560x1440@75, 1920x0, 1.0
|
||||
# monitor = DP-1, 1920x1080@165, 4480x0, 1.0, bitdepth, 10
|
||||
|
||||
monitor = eDP-1, disabled
|
||||
monitor = HDMI-A-1, 2560x1440@75, 0x0, 1.0
|
||||
monitor = DP-1, 1920x1080@165, 2560x0, 1.0, bitdepth, 10
|
||||
|
||||
#monitor = HDMI-A-1, disabled # 1920x1080@60, 0x0, 1
|
||||
#monitor = eDP-1, disabled
|
||||
#monitor = HDMI-A-1, 3840x2160@60, 0x0, 1
|
||||
#monitor = eDP-1, 1920x1080@120, 3840x0, 1
|
|
@ -1,62 +0,0 @@
|
|||
# RULES
|
||||
|
||||
|
||||
windowrule=float,title:^(iwgtk)$
|
||||
windowrule=center,title:^(iwgtk)$
|
||||
windowrule=size 45% 60%,title:^(iwgtk)$
|
||||
|
||||
|
||||
windowrule=float,title:^(Torrent Options)$
|
||||
windowrule=center,title:^(Torrent Options)$
|
||||
windowrule=size 45% 60%,title:^(Torrent Options)$
|
||||
|
||||
|
||||
windowrule=float,title:^(Picture-in-Picture)$
|
||||
windowrule=center,title:^(Picture-in-Picture)$
|
||||
windowrule=size 60% 60%,title:^(Picture-in-Picture)$
|
||||
|
||||
windowrule=float,title:^(connterm)$
|
||||
windowrule=center,title:^(connterm)$
|
||||
windowrule=size 45% 60%,title:^(connterm)$
|
||||
|
||||
|
||||
windowrule=float,title:^(blueterm)$
|
||||
windowrule=center,title:^(blueterm)$
|
||||
windowrule=size 45% 60%,title:^(blueterm)$
|
||||
|
||||
|
||||
windowrule=float,title:^(btoppy)$
|
||||
windowrule=center,title:^(btoppy)$
|
||||
windowrule=size 75% 65%,title:^(btoppy)$
|
||||
|
||||
windowrule=float,class:^(steam)$
|
||||
windowrule=center,class:^(steam)$
|
||||
windowrule=size 95% 90%,class:^(steam)$
|
||||
|
||||
windowrule=float,title:^(pavucontrol)$
|
||||
windowrule=center,title:^(pavucontrol)$
|
||||
windowrule=size 30% 60%,title:^(pavucontrol)$
|
||||
|
||||
windowrule=workspace special silent,title:^(scratchpad)$
|
||||
|
||||
|
||||
|
||||
|
||||
windowrule = float, file_progress
|
||||
windowrule = float, confirm
|
||||
windowrule = float, dialog
|
||||
windowrule = float, download
|
||||
windowrule = float, notification
|
||||
windowrule = float, error
|
||||
windowrule = float, splash
|
||||
windowrule = float, confirmreset
|
||||
windowrule = float, title:Open File
|
||||
windowrule = float, title:branchdialog
|
||||
windowrule = float, Lxappearance
|
||||
windowrule = float, Rofi
|
||||
windowrule = float, pavucontrol
|
||||
windowrule = animation none,Rofi
|
||||
|
||||
layerrule = blur, fuzzel
|
||||
layerrule = blur, waybar
|
||||
layerrule = blur, avizo
|
|
@ -1,21 +0,0 @@
|
|||
bind=SUPER,1,workspace,1
|
||||
bind=SUPER,2,workspace,2
|
||||
bind=SUPER,3,workspace,3
|
||||
bind=SUPER,4,workspace,4
|
||||
bind=SUPER,5,workspace,5
|
||||
bind=SUPER,6,workspace,6
|
||||
bind=SUPER,7,workspace,7
|
||||
bind=SUPER,8,workspace,8
|
||||
bind=SUPER,9,workspace,9
|
||||
bind=SUPER,0,workspace,10
|
||||
bind=SUPERSHIFT,1,movetoworkspace,1
|
||||
bind=SUPERSHIFT,2,movetoworkspace,2
|
||||
bind=SUPERSHIFT,3,movetoworkspace,3
|
||||
bind=SUPERSHIFT,4,movetoworkspace,4
|
||||
bind=SUPERSHIFT,5,movetoworkspace,5
|
||||
bind=SUPERSHIFT,6,movetoworkspace,6
|
||||
bind=SUPERSHIFT,7,movetoworkspace,7
|
||||
bind=SUPERSHIFT,8,movetoworkspace,8
|
||||
bind=SUPERSHIFT,9,movetoworkspace,9
|
||||
bind=SUPERSHIFT,0,movetoworkspace,10
|
||||
|
|
@ -1,20 +0,0 @@
|
|||
bind=SUPER,1,split-workspace,1
|
||||
bind=SUPER,2,split-workspace,2
|
||||
bind=SUPER,3,split-workspace,3
|
||||
bind=SUPER,4,split-workspace,4
|
||||
bind=SUPER,5,split-workspace,5
|
||||
bind=SUPER,6,split-workspace,6
|
||||
bind=SUPER,7,split-workspace,7
|
||||
bind=SUPER,8,split-workspace,8
|
||||
bind=SUPER,9,split-workspace,9
|
||||
bind=SUPER,0,split-workspace,10
|
||||
bind=SUPERSHIFT,1,split-movetoworkspace,1
|
||||
bind=SUPERSHIFT,2,split-movetoworkspace,2
|
||||
bind=SUPERSHIFT,3,split-movetoworkspace,3
|
||||
bind=SUPERSHIFT,4,split-movetoworkspace,4
|
||||
bind=SUPERSHIFT,5,split-movetoworkspace,5
|
||||
bind=SUPERSHIFT,6,split-movetoworkspace,6
|
||||
bind=SUPERSHIFT,7,split-movetoworkspace,7
|
||||
bind=SUPERSHIFT,8,split-movetoworkspace,8
|
||||
bind=SUPERSHIFT,9,split-movetoworkspace,9
|
||||
bind=SUPERSHIFT,0,split-movetoworkspace,10
|
|
@ -1,16 +1,8 @@
|
|||
# DECORATION
|
||||
|
||||
decoration {
|
||||
|
||||
active_opacity = 1
|
||||
inactive_opacity = 1
|
||||
rounding = 0
|
||||
|
||||
blur {
|
||||
enabled = false
|
||||
new_optimizations = true
|
||||
xray = false
|
||||
passes = 3
|
||||
}
|
||||
|
||||
}
|
|
@ -1,7 +1,7 @@
|
|||
env = XDG_CURRENT_DESKTOP, Hyprland
|
||||
env = XDG_SESSION_TYPE, wayland
|
||||
env = XDG_SESSION_DESKTOP, Hyprland
|
||||
exec-once = dbus-update-activation-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
# exec-once = dbus-update-activation-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP
|
||||
|
||||
env = LIBVA_DRIVER_NAME, nvidia
|
||||
env = __GLX_VENDOR_LIBRARY_NAME, nvidia
|
||||
|
@ -28,3 +28,8 @@ env = BROWSER, chromium
|
|||
env = TERM, footclient
|
||||
env = EDITOR, nvim
|
||||
env = _JAVA_AWT_WM_NONREPARENTING, 1
|
||||
|
||||
env = NVD_BACKEND, direct
|
||||
env = ELECTRON_OZONE_PLATFORM_HINT, wayland
|
||||
|
||||
env = AQ_DRM_DEVICES,/dev/dri/card1:/dev/dri/card0
|
|
@ -4,7 +4,7 @@
|
|||
input {
|
||||
kb_layout = us,rs
|
||||
kb_variant = ,yz
|
||||
kb_options = caps:escape,grp:menu_toggle
|
||||
kb_options = caps:escape,grp:win_space_toggle
|
||||
|
||||
follow_mouse = 1
|
||||
|
||||
|
@ -21,24 +21,31 @@ input {
|
|||
tap-and-drag = true
|
||||
disable_while_typing = true
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$LAPTOP_KB_ENABLED = true
|
||||
device {
|
||||
name = at-translated-set-2-keyboard
|
||||
enabled = $LAPTOP_KB_ENABLED
|
||||
}
|
||||
|
||||
cursor {
|
||||
allow_dumb_copy = true
|
||||
use_cpu_buffer = true
|
||||
}
|
||||
|
||||
general {
|
||||
col.inactive_border = 0xff45475a
|
||||
col.active_border = rgba(cba6f7ff) rgba(89b4faff) rgba(94e2d5ff) 10deg
|
||||
|
||||
|
||||
gaps_in = 7
|
||||
gaps_out = 15
|
||||
gaps_out = 14
|
||||
|
||||
layout = dwindle
|
||||
border_size = 0
|
||||
resize_on_border = true
|
||||
|
||||
no_border_on_floating = true
|
||||
allow_tearing = false
|
||||
}
|
||||
|
||||
|
||||
|
@ -49,20 +56,14 @@ gestures {
|
|||
|
||||
|
||||
misc {
|
||||
vfr = true
|
||||
vrr = 1
|
||||
swallow_regex = ^(kitty)$
|
||||
swallow_regex = ^(Alacritty|kitty|footclient|com.mitchellh.ghostty)$
|
||||
enable_swallow = 1
|
||||
disable_hyprland_logo = true
|
||||
}
|
||||
|
||||
|
||||
|
||||
master {
|
||||
no_gaps_when_only = false
|
||||
xwayland {
|
||||
enabled = true
|
||||
}
|
||||
|
||||
dwindle {
|
||||
no_gaps_when_only = false
|
||||
}
|
||||
|
|
@ -1,25 +1,25 @@
|
|||
# KEYBINDS
|
||||
|
||||
bind = SUPER, N, exec, neovide -- -c "Telescope oldfiles"
|
||||
$terminal = footclient
|
||||
$browser = brave
|
||||
|
||||
bind = SUPER, Q, killactive
|
||||
bind = SUPER, Space, fullscreen, 1
|
||||
bind = SUPERSHIFT, Space, fullscreen, 0
|
||||
bind = CTRL, Space, fullscreen, 1
|
||||
bind = CTRLSHIFT, Space, fullscreen, 0
|
||||
bind = SUPERSHIFT, Q, exit
|
||||
bind = SUPER, F, fakefullscreen
|
||||
bind = SUPERSHIFT, F, togglefloating
|
||||
bind = SUPER, Return, exec, footclient
|
||||
bind = SUPER, W, exec, firefox-nightly
|
||||
bind = SUPER, R, exec, footclient -e yazi
|
||||
bind = SUPER, Return, exec, $terminal
|
||||
bind = SUPER, W, exec, $browser
|
||||
bind = SUPER, R, exec, $terminal -e yazi
|
||||
bind = SUPER, D, exec, fuzzel
|
||||
bind = SUPER, L, exec, hyprlock
|
||||
bind = SUPER, V, exec, clippy
|
||||
bind = SUPER, B, exec, killall -SIGUSR1 waybar
|
||||
bind = SUPERSHIFT, B, exec, killall -SIGUSR2 waybar
|
||||
bind = CTRLSHIFT, Escape, exec, footclient --title btoppy -e btop
|
||||
bind = CTRLSHIFT, Escape, exec, $terminal --title=btoppy -e btop
|
||||
bind = SUPER, P, exec, $terminal --title=pulsemixer -e pulsemixer
|
||||
bind = SUPER, End, exec, syspower
|
||||
bind = SUPER, E, exec, iwgtk
|
||||
bind = SUPER, C, exec, /usr/bin/discord --enable-features=UseOzonePlatform,WaylandWindowDecorations --ozone-platform=wayland
|
||||
bind = SUPERSHIFT, E, exec, footclient --title blueterm -e bluetuith
|
||||
bind = SUPERSHIFT, E, exec, $terminal --title=blueterm -e bluetuith
|
||||
|
||||
|
||||
bind = SUPER, S, exec, grimblast copy area
|
||||
|
@ -31,10 +31,10 @@ bind = SUPERCTRL, 2, focusmonitor, HDMI-A-1
|
|||
bind = SUPERCTRL, 3, focusmonitor, DP-1
|
||||
|
||||
|
||||
bind=SUPER,h,movefocus,l
|
||||
bind=SUPER,l,movefocus,r
|
||||
bind=SUPER,k,movefocus,u
|
||||
bind=SUPER,j,movefocus,d
|
||||
bind = SUPER, H, movefocus, l
|
||||
bind = SUPER, L, movefocus, r
|
||||
bind = SUPER, K, movefocus, u
|
||||
bind = SUPER, , movefocus, d
|
||||
|
||||
|
||||
|
19
.config/hypr/slices/monitors.conf
Normal file
19
.config/hypr/slices/monitors.conf
Normal file
|
@ -0,0 +1,19 @@
|
|||
# MONITOR LAYOUT
|
||||
|
||||
bindl = , switch:on:[Lid Switch], exec, hyprctl keyword monitor "eDP-1, disable"
|
||||
bindl = , switch:off:[Lid Switch], exec, hyprctl keyword monitor "eDP-1, preffered, auto, 1"
|
||||
|
||||
# ON OFF OFF
|
||||
# monitor = eDP-1, preffered, auto, 1
|
||||
# monitor = HDMI-A-1, disabled
|
||||
# monitor = DP-1, disabled
|
||||
|
||||
# ON ON ON
|
||||
monitor = HDMI-A-1, 2560x1440@75, 0x0, 1
|
||||
monitor = eDP-1, preffered, auto-left, 1
|
||||
monitor = DP-1, 1920x1080@165, auto-right, 1
|
||||
|
||||
# OFF ON ON
|
||||
# monitor = eDP-1, disabled
|
||||
# monitor = HDMI-A-1, 2560x1440@75, auto, 1
|
||||
# monitor = DP-1, 1920x1080@165, auto-right, 1
|
67
.config/hypr/slices/rules.conf
Normal file
67
.config/hypr/slices/rules.conf
Normal file
|
@ -0,0 +1,67 @@
|
|||
# RULES
|
||||
|
||||
|
||||
windowrulev2=float,title:iwgtk
|
||||
windowrulev2=center,title:iwgtk
|
||||
windowrulev2=size 45% 60%,title:iwgtk
|
||||
|
||||
|
||||
windowrulev2=float, title:pulsemixer
|
||||
windowrulev2=center, title:pulsemixer
|
||||
windowrulev2=size 45% 60%, title:pulsemixer
|
||||
|
||||
|
||||
windowrulev2=float,title:Torrent Options
|
||||
windowrulev2=center,title:Torrent Options
|
||||
windowrulev2=size 45% 60%,title:Torrent Options
|
||||
|
||||
|
||||
windowrulev2=float,title:Picture-in-Picture
|
||||
windowrulev2=center,title:Picture-in-Picture
|
||||
windowrulev2=size 60% 60%,title:Picture-in-Picture
|
||||
|
||||
windowrulev2=float,title:connterm
|
||||
windowrulev2=center,title:connterm
|
||||
windowrulev2=size 45% 60%,title:connterm
|
||||
|
||||
|
||||
windowrulev2=float,title:blueterm
|
||||
windowrulev2=center,title:blueterm
|
||||
windowrulev2=size 45% 60%,title:blueterm
|
||||
|
||||
|
||||
windowrulev2=float,title:btoppy
|
||||
windowrulev2=center,title:btoppy
|
||||
windowrulev2=size 75% 65%,title:btoppy
|
||||
|
||||
windowrulev2=float,class:steam
|
||||
windowrulev2=center,class:steam
|
||||
windowrulev2=size 95% 90%,class:steam
|
||||
|
||||
windowrulev2=float,title:pavucontrol
|
||||
windowrulev2=center,title:pavucontrol
|
||||
windowrulev2=size 30% 60%,title:pavucontrol
|
||||
|
||||
windowrulev2=workspace special silent,title:scratchpad
|
||||
|
||||
|
||||
|
||||
|
||||
windowrule = float, file_progress
|
||||
windowrule = float, confirm
|
||||
windowrule = float, dialog
|
||||
windowrule = float, download
|
||||
windowrule = float, notification
|
||||
windowrule = float, error
|
||||
windowrule = float, splash
|
||||
windowrule = float, confirmreset
|
||||
windowrule = float, title:Open File
|
||||
windowrule = float, title:branchdialog
|
||||
windowrule = float, Lxappearance
|
||||
windowrule = float, Rofi
|
||||
windowrule = float, pavucontrol
|
||||
windowrule = animation none,Rofi
|
||||
|
||||
layerrule = blur, fuzzel
|
||||
layerrule = blur, waybar
|
||||
layerrule = blur, avizo
|
|
@ -1,5 +1,12 @@
|
|||
# Workspace stuff
|
||||
|
||||
workspace = w[tv1], gapsout:0, gapsin:0
|
||||
workspace = f[1], gapsout:0, gapsin:0
|
||||
windowrulev2 = bordersize 0, floating:0, onworkspace:w[tv1]
|
||||
windowrulev2 = rounding 0, floating:0, onworkspace:w[tv1]
|
||||
windowrulev2 = bordersize 0, floating:0, onworkspace:f[1]
|
||||
windowrulev2 = rounding 0, floating:0, onworkspace:f[1]
|
||||
|
||||
|
||||
# workspace = 1, monitor:HDMI-1-A, default:true
|
||||
# workspace = 2, monitor:HDMI-1-A
|
|
@ -1,21 +0,0 @@
|
|||
bind=SUPER,1,workspace,1
|
||||
bind=SUPER,2,workspace,2
|
||||
bind=SUPER,3,workspace,3
|
||||
bind=SUPER,4,workspace,4
|
||||
bind=SUPER,5,workspace,5
|
||||
bind=SUPER,6,workspace,6
|
||||
bind=SUPER,7,workspace,7
|
||||
bind=SUPER,8,workspace,8
|
||||
bind=SUPER,9,workspace,9
|
||||
bind=SUPER,0,workspace,10
|
||||
bind=SUPERSHIFT,1,movetoworkspace,1
|
||||
bind=SUPERSHIFT,2,movetoworkspace,2
|
||||
bind=SUPERSHIFT,3,movetoworkspace,3
|
||||
bind=SUPERSHIFT,4,movetoworkspace,4
|
||||
bind=SUPERSHIFT,5,movetoworkspace,5
|
||||
bind=SUPERSHIFT,6,movetoworkspace,6
|
||||
bind=SUPERSHIFT,7,movetoworkspace,7
|
||||
bind=SUPERSHIFT,8,movetoworkspace,8
|
||||
bind=SUPERSHIFT,9,movetoworkspace,9
|
||||
bind=SUPERSHIFT,0,movetoworkspace,10
|
||||
|
|
@ -1,5 +1,6 @@
|
|||
# vim: syntax=config
|
||||
|
||||
sub-auto=fuzzy
|
||||
sub-file-paths=**
|
||||
|
||||
###########
|
||||
# General #
|
||||
|
@ -17,7 +18,7 @@ use-filedir-conf # look for additional config files in th
|
|||
autofit-larger=100%x95% # resize window in case it's larger than W%xH% of the screen
|
||||
cursor-autohide-fs-only # don't autohide the cursor in window mode, only fullscreen
|
||||
input-media-keys=no # enable/disable OSX media keys
|
||||
cursor-autohide=yes
|
||||
cursor-autohide=1
|
||||
force-seekable=yes
|
||||
|
||||
screenshot-format=png
|
||||
|
@ -41,9 +42,9 @@ ytdl-format=bestvideo[height<=?1080][fps<=?30][vcodec!=?vp9][protocol!=http_dash
|
|||
# Cache #
|
||||
#########
|
||||
|
||||
cache=no
|
||||
demuxer-max-bytes=3GiB
|
||||
demuxer-max-back-bytes=2GiB
|
||||
cache=yes
|
||||
demuxer-max-bytes=1GiB
|
||||
demuxer-max-back-bytes=1GiB
|
||||
|
||||
|
||||
#############
|
||||
|
@ -51,7 +52,7 @@ demuxer-max-back-bytes=2GiB
|
|||
#############
|
||||
|
||||
osd-level=1 # enable osd and display --osd-status-msg on interaction
|
||||
osd-duration=2500 # hide the osd after x ms
|
||||
osd-duration=250 # hide the osd after x ms
|
||||
osd-status-msg='${time-pos} / ${duration}${?percent-pos: (${percent-pos}%)}${?frame-drop-count:${!frame-drop-count==0: Dropped: ${frame-drop-count}}}\n${?chapter:Chapter: ${chapter}}'
|
||||
|
||||
osd-font='Source Sans Pro'
|
||||
|
@ -81,7 +82,7 @@ sub-file-paths-append=subtitles
|
|||
|
||||
embeddedfonts=yes # use embedded fonts for SSA/ASS subs
|
||||
sub-fix-timing=no # do not try to fix gaps (which might make it worse in some cases)
|
||||
sub-ass-force-style=Kerning=yes # allows you to override style parameters of ASS scripts
|
||||
sub-ass-style-overrides=Kerning=yes # allows you to override style parameters of ASS scripts
|
||||
sub-use-margins
|
||||
sub-ass-force-margins
|
||||
|
||||
|
@ -129,7 +130,7 @@ tscale=oversample # [sharp] oversample <-> linear (triangle
|
|||
# "yes" is currently bugged: https://github.com/mpv-player/mpv/issues/4988
|
||||
#icc-profile-auto
|
||||
#icc-force-contrast=1000 # silence some warning because the profile is bad
|
||||
hwdec=no
|
||||
hwdec=yes
|
||||
|
||||
[high-quality]
|
||||
profile-desc=cond:is_high(get('width', 0), get('height', 0), get('estimated-vf-fps', 0))
|
||||
|
|
280
.config/mpv/scripts/fuzzydir.lua
Normal file
280
.config/mpv/scripts/fuzzydir.lua
Normal file
|
@ -0,0 +1,280 @@
|
|||
--[[
|
||||
fuzzydir / by sibwaf / https://github.com/sibwaf/mpv-scripts
|
||||
|
||||
Allows using "**" wildcards in sub-file-paths and audio-file-paths
|
||||
so you don't have to specify all the possible directory names.
|
||||
|
||||
Basically, allows you to do this and never have the need to edit any paths ever again:
|
||||
audio-file-paths = **
|
||||
sub-file-paths = **
|
||||
|
||||
MIT license - do whatever you want, but I'm not responsible for any possible problems.
|
||||
Please keep the URL to the original repository. Thanks!
|
||||
]]
|
||||
|
||||
--[[
|
||||
Configuration:
|
||||
|
||||
# enabled
|
||||
|
||||
Determines whether the script is enabled or not
|
||||
|
||||
# max_search_depth
|
||||
|
||||
Determines the max depth of recursive search, should be >= 1
|
||||
|
||||
Examples for "sub-file-paths = **":
|
||||
"max_search_depth = 1" => mpv will be able to find [xyz.ass, subs/xyz.ass]
|
||||
"max_search_depth = 2" => mpv will be able to find [xyz.ass, subs/xyz.ass, subs/moresubs/xyz.ass]
|
||||
|
||||
Please be careful when setting this value too high as it can result in awful performance or even stack overflow
|
||||
|
||||
|
||||
# discovery_threshold
|
||||
|
||||
fuzzydir will skip paths which contain more than discovery_threshold directories in them
|
||||
|
||||
This is done to keep at least some garbage from getting into *-file-paths properties in case of big collections:
|
||||
- dir1 <- will be ignored on opening video.mp4 as it's probably unrelated to the file
|
||||
- ...
|
||||
- dir999 <- will be ignored
|
||||
- video.mp4
|
||||
|
||||
Use 0 to disable this behavior completely
|
||||
|
||||
|
||||
# use_powershell
|
||||
|
||||
fuzzydir will use PowerShell to traverse directories when it's available
|
||||
|
||||
Can be faster in some cases, but can also be significantly slower
|
||||
]]
|
||||
|
||||
local msg = require 'mp.msg'
|
||||
local utils = require 'mp.utils'
|
||||
local options = require 'mp.options'
|
||||
|
||||
o = {
|
||||
enabled = true,
|
||||
max_search_depth = 3,
|
||||
discovery_threshold = 10,
|
||||
use_powershell = false,
|
||||
}
|
||||
options.read_options(o, _, function() end)
|
||||
|
||||
----------
|
||||
|
||||
local default_audio_paths = mp.get_property_native("options/audio-file-paths")
|
||||
local default_sub_paths = mp.get_property_native("options/sub-file-paths")
|
||||
|
||||
function foreach(list, action)
|
||||
for _, item in pairs(list) do
|
||||
action(item)
|
||||
end
|
||||
end
|
||||
|
||||
function starts_with(str, prefix)
|
||||
return string.sub(str, 1, string.len(prefix)) == prefix
|
||||
end
|
||||
|
||||
function ends_with(str, suffix)
|
||||
return suffix == "" or string.sub(str, -string.len(suffix)) == suffix
|
||||
end
|
||||
|
||||
function add_all(to, from)
|
||||
for index, element in pairs(from) do
|
||||
table.insert(to, element)
|
||||
end
|
||||
end
|
||||
|
||||
function contains(t, e)
|
||||
for index, element in pairs(t) do
|
||||
if element == e then
|
||||
return true
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
function normalize(path)
|
||||
if path == "." then
|
||||
return ""
|
||||
end
|
||||
|
||||
if starts_with(path, "./") or starts_with(path, ".\\") then
|
||||
path = string.sub(path, 3, -1)
|
||||
end
|
||||
if ends_with(path, "/") or ends_with(path, "\\") then
|
||||
path = string.sub(path, 1, -2)
|
||||
end
|
||||
|
||||
return path
|
||||
end
|
||||
|
||||
function call_command(command)
|
||||
local command_string = ""
|
||||
for _, part in pairs(command) do
|
||||
command_string = command_string .. part .. " "
|
||||
end
|
||||
|
||||
msg.trace("Calling external command:", command_string)
|
||||
|
||||
local process = mp.command_native({
|
||||
name = "subprocess",
|
||||
playback_only = false,
|
||||
capture_stdout = true,
|
||||
capture_stderr = true,
|
||||
args = command,
|
||||
})
|
||||
|
||||
if process.status ~= 0 then
|
||||
msg.verbose("External command failed with status " .. process.status .. ": " .. command_string)
|
||||
if process.stderr ~= "" then
|
||||
msg.debug(process.stderr)
|
||||
end
|
||||
|
||||
return nil
|
||||
end
|
||||
|
||||
local result = {}
|
||||
for line in string.gmatch(process.stdout, "([^\r\n]+)") do
|
||||
table.insert(result, line)
|
||||
end
|
||||
return result
|
||||
end
|
||||
|
||||
-- Platform-dependent optimization
|
||||
|
||||
local powershell_version = nil
|
||||
if o.use_powershell then
|
||||
powershell_version = call_command({
|
||||
"powershell",
|
||||
"-NoProfile",
|
||||
"-Command",
|
||||
"$Host.Version.Major",
|
||||
})
|
||||
end
|
||||
if powershell_version ~= nil then
|
||||
powershell_version = tonumber(powershell_version[1])
|
||||
end
|
||||
if powershell_version == nil then
|
||||
powershell_version = -1
|
||||
end
|
||||
msg.debug("PowerShell version", powershell_version)
|
||||
|
||||
function fast_readdir(path)
|
||||
if powershell_version >= 3 then
|
||||
msg.trace("Scanning", path, "with PowerShell")
|
||||
result = call_command({
|
||||
"powershell",
|
||||
"-NoProfile",
|
||||
"-Command",
|
||||
[[
|
||||
$dirs = Get-ChildItem -LiteralPath ]] .. string.format("%q", path) .. [[ -Directory
|
||||
foreach($dir in $dirs) {
|
||||
$u8clip = [System.Text.Encoding]::UTF8.GetBytes($dir.Name)
|
||||
[Console]::OpenStandardOutput().Write($u8clip, 0, $u8clip.Length)
|
||||
Write-Host ""
|
||||
} ]],
|
||||
})
|
||||
msg.trace("Finished scanning", path, "with PowerShell")
|
||||
return result
|
||||
end
|
||||
|
||||
msg.trace("Scanning", path, "with default readdir")
|
||||
result = utils.readdir(path, "dirs")
|
||||
msg.trace("Finished scanning", path, "with default readdir")
|
||||
return result
|
||||
end
|
||||
|
||||
-- Platform-dependent optimization end
|
||||
|
||||
function traverse(search_path, current_path, level, cache)
|
||||
local full_path = utils.join_path(search_path, current_path)
|
||||
|
||||
if level > o.max_search_depth then
|
||||
msg.trace("Traversed too deep, skipping scan for", full_path)
|
||||
return {}
|
||||
end
|
||||
|
||||
if cache[full_path] ~= nil then
|
||||
msg.trace("Returning from cache for", full_path)
|
||||
return cache[full_path]
|
||||
end
|
||||
|
||||
local result = {}
|
||||
|
||||
local discovered_paths = fast_readdir(full_path)
|
||||
if discovered_paths == nil then
|
||||
-- noop
|
||||
msg.debug("Unable to scan " .. full_path .. ", skipping")
|
||||
elseif o.discovery_threshold > 0 and #discovered_paths > o.discovery_threshold then
|
||||
-- noop
|
||||
msg.debug("Too many directories in " .. full_path .. ", skipping")
|
||||
else
|
||||
for _, discovered_path in pairs(discovered_paths) do
|
||||
local new_path = utils.join_path(current_path, discovered_path)
|
||||
|
||||
table.insert(result, new_path)
|
||||
add_all(result, traverse(search_path, new_path, level + 1, cache))
|
||||
end
|
||||
end
|
||||
|
||||
cache[full_path] = result
|
||||
|
||||
return result
|
||||
end
|
||||
|
||||
function explode(raw_paths, search_path, cache)
|
||||
local result = {}
|
||||
for _, raw_path in pairs(raw_paths) do
|
||||
local parent, leftover = utils.split_path(raw_path)
|
||||
if leftover == "**" then
|
||||
msg.trace("Expanding wildcard for", raw_path)
|
||||
table.insert(result, parent)
|
||||
add_all(result, traverse(search_path, parent, 1, cache))
|
||||
else
|
||||
msg.trace("Path", raw_path, "doesn't have a wildcard, keeping as-is")
|
||||
table.insert(result, raw_path)
|
||||
end
|
||||
end
|
||||
|
||||
local normalized = {}
|
||||
for index, path in pairs(result) do
|
||||
local normalized_path = normalize(path)
|
||||
if not contains(normalized, normalized_path) and normalized_path ~= "" then
|
||||
table.insert(normalized, normalized_path)
|
||||
end
|
||||
end
|
||||
|
||||
return normalized
|
||||
end
|
||||
|
||||
function explode_all()
|
||||
if not o.enabled then return end
|
||||
msg.debug("max_search_depth = ".. o.max_search_depth .. ", discovery_threshold = " .. o.discovery_threshold)
|
||||
|
||||
local video_path = mp.get_property("path")
|
||||
local search_path, _ = utils.split_path(video_path)
|
||||
msg.debug("search_path = " .. search_path)
|
||||
|
||||
local cache = {}
|
||||
|
||||
foreach(default_audio_paths, function(it) msg.debug("audio-file-paths:", it) end)
|
||||
local audio_paths = explode(default_audio_paths, search_path, cache)
|
||||
foreach(audio_paths, function(it) msg.debug("Adding to audio-file-paths:", it) end)
|
||||
mp.set_property_native("options/audio-file-paths", audio_paths)
|
||||
|
||||
msg.verbose("Done expanding audio-file-paths")
|
||||
|
||||
foreach(default_sub_paths, function(it) msg.debug("sub-file-paths:", it) end)
|
||||
local sub_paths = explode(default_sub_paths, search_path, cache)
|
||||
foreach(sub_paths, function(it) msg.debug("Adding to sub-file-paths:", it) end)
|
||||
mp.set_property_native("options/sub-file-paths", sub_paths)
|
||||
|
||||
msg.verbose("Done expanding sub-file-paths")
|
||||
|
||||
msg.debug("Done expanding paths")
|
||||
end
|
||||
|
||||
mp.add_hook("on_load", 50, explode_all)
|
124
.config/mpv/scripts/sub-fonts-dir-auto.lua
Normal file
124
.config/mpv/scripts/sub-fonts-dir-auto.lua
Normal file
|
@ -0,0 +1,124 @@
|
|||
--[[
|
||||
|
||||
Automatically look for a fonts directory to use with `sub-fonts-dir`.
|
||||
|
||||
This mpv Lua script will automatically use the `sub-fonts-dir` option (to
|
||||
override the default `~~/fonts` location) if it find a `Fonts` directory
|
||||
alongside the currently playing file. (The name of the directory is
|
||||
matched case-insensitively.)
|
||||
|
||||
**NOTE:** The `sub-fonts-dir` option has been submitted as part of [PR
|
||||
#9856](https://github.com/mpv-player/mpv/pull/9856). Until it is merged
|
||||
upstream, you will have to download and compile the [mpv
|
||||
source](https://github.com/mpv-player/mpv) yourself.
|
||||
|
||||
|
||||
USAGE:
|
||||
|
||||
Simply drop this script in your scripts configuration directory (usually
|
||||
`~/.config/mpv/scripts/`).
|
||||
|
||||
|
||||
REQUIREMENTS:
|
||||
|
||||
This script requires a version of mpv that includes the `sub-fonts-dir`
|
||||
option.
|
||||
|
||||
|
||||
NOTES:
|
||||
|
||||
- Any `--sub-fonts-dir` option passed on the command-line will override
|
||||
this script.
|
||||
|
||||
- When going through a playlist, `sub-fonts-dir` will be dynamically
|
||||
updated for each individual file.
|
||||
|
||||
- This script will output some additional information on higher verbosity
|
||||
levels (`-v`). To increase the verbosity for this script only, use
|
||||
`--msg-level=sub_fonts_dir_auto=v` (or `=debug` for more output).
|
||||
|
||||
|
||||
AUTHOR:
|
||||
|
||||
Frédéric Brière (fbriere@fbriere.net)
|
||||
|
||||
Licensed under the GNU General Public License, version 2 or later.
|
||||
|
||||
--]]
|
||||
|
||||
|
||||
local utils = require 'mp.utils'
|
||||
local msg = require 'mp.msg'
|
||||
-- msg.trace() was added in 0.28.0 -- define it ourselves if it's missing
|
||||
if msg.trace == nil then
|
||||
msg.trace = function(...) return mp.log("trace", ...) end
|
||||
end
|
||||
|
||||
|
||||
-- Directory name we are looking for (case-insensitive)
|
||||
local FONTS_DIR_NAME = "Fonts"
|
||||
-- Option name that we want to set
|
||||
local OPTION_NAME = "sub-fonts-dir"
|
||||
-- Make sure this option is available in this version of mpv
|
||||
do
|
||||
local _, err = mp.get_property(OPTION_NAME)
|
||||
if err then
|
||||
msg.error(string.format("This version of mpv does not support the %s option", OPTION_NAME))
|
||||
return
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
-- Whether a path is a directory
|
||||
local function isdir(path)
|
||||
return utils.readdir(path .. "/.") ~= nil
|
||||
end
|
||||
|
||||
-- Set an option's value for this file, without overriding the command-line
|
||||
local function set_option(name, value)
|
||||
if not mp.get_property_bool(string.format("option-info/%s/set-from-commandline", name)) then
|
||||
msg.verbose(string.format("Setting %s to %q", name, value))
|
||||
mp.set_property(string.format("file-local-options/%s", name), value)
|
||||
else
|
||||
msg.debug(string.format("Option %s was set on command-line -- leaving it as-is", name))
|
||||
end
|
||||
end
|
||||
|
||||
-- Find a "Fonts" directory under a single path
|
||||
local function find_fonts_dir(path)
|
||||
local entries = utils.readdir(path, "dirs")
|
||||
if entries == nil then
|
||||
-- mpv will throw an error message soon enough, no need to intervene
|
||||
return
|
||||
end
|
||||
msg.trace(string.format("Iterating over directories under %q", path))
|
||||
for _, entry in ipairs(entries) do
|
||||
msg.trace("Candidate directory:", entry)
|
||||
if entry:lower() == FONTS_DIR_NAME:lower() then
|
||||
msg.trace("Match found")
|
||||
return utils.join_path(path, entry)
|
||||
end
|
||||
end
|
||||
msg.trace("No match found")
|
||||
end
|
||||
|
||||
-- "on_load" hook callback for when a file is about to be loaded.
|
||||
local function on_load()
|
||||
local path = mp.get_property("path")
|
||||
if isdir(path) then
|
||||
msg.debug("Playing 'file' is actually a directory -- skipping")
|
||||
return
|
||||
end
|
||||
|
||||
local path_dir = utils.split_path(path)
|
||||
-- Cosmetic nitpicking: That trailing "/" just looks annoying to me
|
||||
path_dir = path_dir:gsub("(.)/+$", "%1")
|
||||
|
||||
msg.debug(string.format("Searching %q for fonts directory", path_dir))
|
||||
local fonts_dir = find_fonts_dir(path_dir)
|
||||
if fonts_dir then
|
||||
msg.debug("Found fonts directory:", fonts_dir)
|
||||
set_option(OPTION_NAME, fonts_dir)
|
||||
end
|
||||
end
|
||||
mp.add_hook("on_load", 50, on_load)
|
12
.config/msmtp/config
Normal file
12
.config/msmtp/config
Normal file
|
@ -0,0 +1,12 @@
|
|||
defaults
|
||||
tls on
|
||||
|
||||
account brk
|
||||
auth on
|
||||
host mail.bonsai.cool
|
||||
port 587
|
||||
user brk
|
||||
from brk@bonsai.cool
|
||||
passwordeval gopass show -o bonsai/mail
|
||||
|
||||
account default: brk
|
|
@ -1 +1 @@
|
|||
Subproject commit ca0d4faec420a99de6141fccbdcad0ecc085d1ff
|
||||
Subproject commit 1776bc8edcc5cc6da250133e9153d1229f75d610
|
|
@ -11,6 +11,7 @@ settings:
|
|||
colors.webpage.darkmode.enabled:
|
||||
global: false
|
||||
content.notifications.enabled:
|
||||
https://www.facebook.com: true
|
||||
https://www.netflix.com: true
|
||||
content.register_protocol_handler:
|
||||
https://mail.proton.me#mailto=%25s: true
|
||||
|
|
|
@ -193,8 +193,8 @@ c.tabs.show = 'multiple'
|
|||
|
||||
# Setting default page for when opening new tabs or new windows with
|
||||
# commands like :open -t and :open -w .
|
||||
c.url.default_page = 'google.com'
|
||||
c.url.start_pages = 'google.com'
|
||||
c.url.default_page = 'bonsai.cool'
|
||||
c.url.start_pages = 'bonsai.cool'
|
||||
|
||||
# Search engines which can be used via the address bar. Maps a search
|
||||
# engine name (such as `DEFAULT`, or `ddg`) to a URL with a `{}`
|
||||
|
@ -214,10 +214,10 @@ c.url.start_pages = 'google.com'
|
|||
# the search engine name to the search term, e.g. `:open google
|
||||
# qutebrowser`.
|
||||
# Type: Dict
|
||||
c.url.searchengines = {'DEFAULT': 'https://google.com/search?q={}',
|
||||
c.url.searchengines = {'DEFAULT': "https://search.bonsai.cool/search?q={}",
|
||||
'am': 'https://www.amazon.com/s?k={}',
|
||||
'aw': 'https://wiki.archlinux.org/?search={}',
|
||||
'goog': 'https://www.google.com/search?q={}',
|
||||
'g': 'https://www.google.com/search?q={}',
|
||||
'hoog': 'https://hoogle.haskell.org/?hoogle={}',
|
||||
're': 'https://www.reddit.com/r/{}',
|
||||
'ub': 'https://www.urbandictionary.com/define.php?term={}',
|
||||
|
|
|
@ -1,91 +1,31 @@
|
|||
{
|
||||
"height": 35,
|
||||
[{
|
||||
"layer": "top",
|
||||
"position": "top",
|
||||
"modules-left": ["hyprland/workspaces"],
|
||||
"modules-center": [],
|
||||
"modules-right": ["cpu", "temperature", "battery", "network", "clock"],
|
||||
"output": "HDMI-A-1",
|
||||
"width": 10,
|
||||
"position": "left",
|
||||
"reload_style_on_change": true,
|
||||
"modules-left": ["cpu", "temperature", ],
|
||||
"modules-center": ["hyprland/workspaces"],
|
||||
"modules-right": ["network", "clock"],
|
||||
|
||||
"wlr/workspaces": {
|
||||
"disable-scroll": true,
|
||||
"hyprland/workspaces": {
|
||||
"active-only": false,
|
||||
"all-outputs": false,
|
||||
"on-click": "activate",
|
||||
"on-scroll-up": "hyprctl dispatch workspace e+1",
|
||||
"on-scroll-down": "hyprctl dispatch workspace e-1",
|
||||
},
|
||||
|
||||
|
||||
"custom/bar" : {
|
||||
"interval" : "once",
|
||||
"format" : "▊",
|
||||
"tooltip" : false
|
||||
},
|
||||
|
||||
|
||||
"custom/launcher": {
|
||||
"interval": "once",
|
||||
"format": "",
|
||||
"tooltip": false
|
||||
},
|
||||
|
||||
"custom/pkgs": {
|
||||
"interval": "once",
|
||||
"format": "{}",
|
||||
"exec" : "hyprctl version -j | jq '.tag' -r | cut -d'-' -f1"
|
||||
},
|
||||
|
||||
"custom/audio_idle_inhibitor": {
|
||||
"format": "{icon}",
|
||||
"exec": "sway-audio-idle-inhibit --dry-print-both-waybar",
|
||||
"exec-if": "which sway-audio-idle-inhibit",
|
||||
"return-type": "json",
|
||||
"format-icons": {
|
||||
"output": "",
|
||||
"input": "",
|
||||
"output-input": " ",
|
||||
"none": ""
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
"custom/cpu": {
|
||||
"interval": "once",
|
||||
"format": "",
|
||||
},
|
||||
|
||||
"cpu": {
|
||||
"interval": 1,
|
||||
"format": " \t{usage}%",
|
||||
"max-length": 10,
|
||||
"format": "{usage}%",
|
||||
"max-length": 4,
|
||||
"min-length": 4
|
||||
},
|
||||
|
||||
|
||||
|
||||
"custom/temp": {
|
||||
"interval": "once",
|
||||
"format": "",
|
||||
},
|
||||
|
||||
"temperature": {
|
||||
"hwmon-path-abs": "/sys/devices/platform/coretemp.0/hwmon",
|
||||
"input-filename": "temp1_input",
|
||||
"format": "{temperatureC}°C",
|
||||
"format": "{temperatureC}°",
|
||||
},
|
||||
|
||||
|
||||
|
||||
|
||||
"backlight": {
|
||||
"format": "{icon}",
|
||||
"format-icons": ["", "", "", "", "", "", "", "", ""],
|
||||
"on-scroll-up": "light -A 1",
|
||||
"on-scroll-down": "light -U 1"
|
||||
},
|
||||
|
||||
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon}",
|
||||
"format-bluetooth": "{icon} {volume}% {format_source}",
|
||||
|
@ -104,24 +44,10 @@
|
|||
"on-click": "pactl set-sink-mute @DEFAULT_SINK@ toggle"
|
||||
},
|
||||
|
||||
|
||||
|
||||
"custom/net": {
|
||||
"interval": "once",
|
||||
"format": "",
|
||||
},
|
||||
|
||||
"network": {
|
||||
"format-wifi": " {essid}",
|
||||
"format-wifi": " ",
|
||||
"format-ethernet": " ",
|
||||
"format-disconnected": " ",
|
||||
"max-length" : 20
|
||||
},
|
||||
|
||||
|
||||
"custom/bat" : {
|
||||
"interval" : "once",
|
||||
"format" : ""
|
||||
},
|
||||
|
||||
"battery": {
|
||||
|
@ -133,24 +59,175 @@
|
|||
"critical": 15
|
||||
},
|
||||
"max-length": 20,
|
||||
"format": " {icon} {capacity}%",
|
||||
"format-warning": " {icon} {capacity}%",
|
||||
"format-critical": " {icon} {capacity}%",
|
||||
"format-charging": " {icon} {capacity}%",
|
||||
"format-plugged": " {icon} {capacity}%",
|
||||
"format": "{icon}",
|
||||
"format-warning": "",
|
||||
"format-critical": "",
|
||||
"format-charging": "",
|
||||
"format-plugged": "",
|
||||
"format-alt": " {icon} {time} ",
|
||||
"format-full": "",
|
||||
"format-icons": [" ", " ", " ", " ", " "]
|
||||
},
|
||||
|
||||
"custom/clock" : {
|
||||
"format" : ""
|
||||
"format-icons": ["", "", "", "", ""]
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format-alt": "<span> </span> {:%a %b %d}",
|
||||
"format": " {:%H:%M}"
|
||||
"format": "{:%H\n%M}"
|
||||
},
|
||||
},
|
||||
|
||||
{
|
||||
"layer": "top",
|
||||
"output": "DP-1",
|
||||
"width": 10,
|
||||
"position": "right",
|
||||
"reload_style_on_change": true,
|
||||
"modules-left": ["cpu", "temperature", ],
|
||||
"modules-center": ["hyprland/workspaces"],
|
||||
"modules-right": ["network", "clock"],
|
||||
|
||||
"hyprland/workspaces": {
|
||||
"active-only": false,
|
||||
"on-click": "activate",
|
||||
},
|
||||
|
||||
"cpu": {
|
||||
"interval": 1,
|
||||
"format": "{usage}%",
|
||||
"max-length": 4,
|
||||
"min-length": 4
|
||||
},
|
||||
|
||||
"temperature": {
|
||||
"hwmon-path-abs": "/sys/devices/platform/coretemp.0/hwmon",
|
||||
"input-filename": "temp1_input",
|
||||
"format": "{temperatureC}°",
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon}",
|
||||
"format-bluetooth": "{icon} {volume}% {format_source}",
|
||||
"format-bluetooth-muted": "x {icon} {format_source}",
|
||||
"format-muted": "婢",
|
||||
"format-icons": {
|
||||
"headphone": "",
|
||||
"hands-free": "",
|
||||
"headset": "",
|
||||
"phone": "",
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": ["", "", ""]
|
||||
},
|
||||
"on-click-right": "pavucontrol",
|
||||
"on-click": "pactl set-sink-mute @DEFAULT_SINK@ toggle"
|
||||
},
|
||||
|
||||
"network": {
|
||||
"format-wifi": " ",
|
||||
"format-ethernet": " ",
|
||||
"format-disconnected": " ",
|
||||
},
|
||||
|
||||
"battery": {
|
||||
"bat": "BAT0",
|
||||
"adapter": "ADP0",
|
||||
"interval": 60,
|
||||
"states": {
|
||||
"warning": 30,
|
||||
"critical": 15
|
||||
},
|
||||
"max-length": 20,
|
||||
"format": "{icon}",
|
||||
"format-warning": "",
|
||||
"format-critical": "",
|
||||
"format-charging": "",
|
||||
"format-plugged": "",
|
||||
"format-alt": " {icon} {time} ",
|
||||
"format-full": "",
|
||||
"format-icons": ["", "", "", "", ""]
|
||||
},
|
||||
|
||||
|
||||
}
|
||||
"clock": {
|
||||
"format-alt": "<span> </span> {:%a %b %d}",
|
||||
"format": "{:%H\n%M}"
|
||||
},
|
||||
|
||||
},
|
||||
{
|
||||
"layer": "top",
|
||||
"output": "eDP-1",
|
||||
"width": 10,
|
||||
"position": "left",
|
||||
"reload_style_on_change": true,
|
||||
"modules-left": ["cpu", "temperature", ],
|
||||
"modules-center": ["hyprland/workspaces"],
|
||||
"modules-right": ["battery", "network", "clock"],
|
||||
|
||||
"hyprland/workspaces": {
|
||||
"active-only": false,
|
||||
"on-click": "activate",
|
||||
},
|
||||
|
||||
"cpu": {
|
||||
"interval": 1,
|
||||
"format": "{usage}%",
|
||||
"max-length": 4,
|
||||
"min-length": 4
|
||||
},
|
||||
|
||||
"temperature": {
|
||||
"hwmon-path-abs": "/sys/devices/platform/coretemp.0/hwmon",
|
||||
"input-filename": "temp1_input",
|
||||
"format": "{temperatureC}°",
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon}",
|
||||
"format-bluetooth": "{icon} {volume}% {format_source}",
|
||||
"format-bluetooth-muted": "x {icon} {format_source}",
|
||||
"format-muted": "婢",
|
||||
"format-icons": {
|
||||
"headphone": "",
|
||||
"hands-free": "",
|
||||
"headset": "",
|
||||
"phone": "",
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": ["", "", ""]
|
||||
},
|
||||
"on-click-right": "pavucontrol",
|
||||
"on-click": "pactl set-sink-mute @DEFAULT_SINK@ toggle"
|
||||
},
|
||||
|
||||
"network": {
|
||||
"format-wifi": " ",
|
||||
"format-ethernet": " ",
|
||||
"format-disconnected": " ",
|
||||
},
|
||||
|
||||
"battery": {
|
||||
"bat": "BAT0",
|
||||
"adapter": "ADP0",
|
||||
"interval": 60,
|
||||
"states": {
|
||||
"warning": 30,
|
||||
"critical": 15
|
||||
},
|
||||
"max-length": 20,
|
||||
"format": "{icon}",
|
||||
"format-warning": "",
|
||||
"format-critical": "",
|
||||
"format-charging": "",
|
||||
"format-plugged": "",
|
||||
"format-alt": " {icon} {time} ",
|
||||
"format-full": "",
|
||||
"format-icons": ["", "", "", "", ""]
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format-alt": "<span> </span> {:%a %b %d}",
|
||||
"format": "{:%H\n%M}"
|
||||
},
|
||||
},
|
||||
|
||||
]
|
||||
|
|
|
@ -3,34 +3,49 @@
|
|||
/* margin: top right bottom left */
|
||||
/* Spacing outside the element */
|
||||
|
||||
/* padding: top right bottom left */
|
||||
/* Spacing inside the element */
|
||||
|
||||
* {
|
||||
font-family: FiraCode Mono Nerd Font;
|
||||
font-size: 15px;
|
||||
font-size: 13px;
|
||||
min-height: 0;
|
||||
margin: 0px;
|
||||
padding: 2px 0px;
|
||||
border-radius: 6px;
|
||||
}
|
||||
|
||||
#clock,
|
||||
#battery,
|
||||
#cpu,
|
||||
#temperature,
|
||||
#backlight,
|
||||
#network,
|
||||
#pulseaudio {
|
||||
color: @crust;
|
||||
font-family: FiraCode Mono Nerd Font;
|
||||
font-size: 13px;
|
||||
min-height: 0;
|
||||
margin: 4px;
|
||||
padding: 6px 1px;
|
||||
background: #1B1B1B;
|
||||
}
|
||||
|
||||
|
||||
window#waybar {
|
||||
background-color: #0A0A0A;
|
||||
background-color: #070707;
|
||||
color: @text;
|
||||
transition-property: background-color;
|
||||
transition-duration: 0.5s;
|
||||
border-radius: 0px;
|
||||
transition-duration: .5s;
|
||||
margin: 16px 16px;
|
||||
border-radius: 0px;
|
||||
margin: 0px;
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
window#waybar.hidden {
|
||||
opacity: 0.2;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
color: #A9A1E1;
|
||||
background: #191919;
|
||||
border-radius: 8px;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 10px 5px 10px 5px;
|
||||
background: #1B1B1B;
|
||||
transition: all 0.3s ease-in-out;
|
||||
}
|
||||
|
||||
|
@ -40,183 +55,36 @@ window#waybar.hidden {
|
|||
}
|
||||
|
||||
#workspaces button.active {
|
||||
color: #A9A1E1;
|
||||
background: #141414;
|
||||
border-bottom: 2px solid #A9A1E1;
|
||||
border-radius: 8px;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 10px 5px 10px 5px;
|
||||
}
|
||||
|
||||
#custom-launcher,
|
||||
#clock,
|
||||
#battery,
|
||||
#cpu,
|
||||
#temperature,
|
||||
#backlight,
|
||||
#network,
|
||||
#pulseaudio,
|
||||
#custom-dunst,
|
||||
#custom-powermenu{
|
||||
padding: 20px 20px;
|
||||
margin: 7px 0px 10px 0px;
|
||||
border-radius: 10px;
|
||||
color: @crust;
|
||||
}
|
||||
|
||||
#window,
|
||||
|
||||
|
||||
|
||||
|
||||
#custom-audio_idle_inhibitor {
|
||||
padding: 0px 15px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
background-color: #C678DD;
|
||||
color: @joksi-bg;
|
||||
border-radius: 10px;
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#custom-launcher {
|
||||
padding: 0px 15px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
background-color: #C678DD;
|
||||
color: @joksi-bg;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
#custom-pkgs {
|
||||
padding: 0px 15px 0px 10px;
|
||||
margin: 7px 0px 10px 0px;
|
||||
background-color: @joksi-bg;
|
||||
color: #C678DD;
|
||||
border-radius: 0px 10px 10px 0px;
|
||||
}
|
||||
|
||||
#custom-cpu {
|
||||
background-color: #51AFEF;
|
||||
color: @joksi-bg;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
|
||||
font-size: 20px;
|
||||
color: #1B1B1B;
|
||||
background: #A9A1E1;
|
||||
padding: 0px;
|
||||
margin: 7px;
|
||||
}
|
||||
|
||||
#cpu {
|
||||
background: #141414;
|
||||
color: #51AFEF;
|
||||
border-radius: 8px 0px 0px 8px;
|
||||
border-bottom: 2px solid #51AFEF;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 10px 0px 10px 0px;
|
||||
|
||||
}
|
||||
|
||||
#custom-temp {
|
||||
background: #141414;
|
||||
color: @joksi-bg;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
|
||||
#temperature {
|
||||
background: #141414;
|
||||
color: #51AFEF;
|
||||
border-bottom: 2px solid #51AFEF;
|
||||
border-radius: 0px 8px 8px 0px;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 10px 5px 10px 0px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
#backlight {
|
||||
background-color: #CCCCCC;
|
||||
padding: 0px 10px 0px 10px;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
}
|
||||
|
||||
|
||||
#pulseaudio {
|
||||
background-color: @joksi-bg;
|
||||
color: #A9A1E1;
|
||||
padding: 0px 10px 0px 10px;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
#custom-net {
|
||||
background-color: #A9A1E1;
|
||||
color: @joksi-bg;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
padding: 0px 15px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
#network {
|
||||
color: #A9A1E1;
|
||||
background: #141414;
|
||||
border-bottom: 2px solid #A9A1E1;
|
||||
border-radius: 8px;
|
||||
padding: 0px 5px 0px 5px;
|
||||
margin: 10px 5px 10px 5px;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
|
||||
|
||||
#custom-bat {
|
||||
background-color: #EC5F67;
|
||||
color: @joksi-bg;
|
||||
border-radius: 10px 0px 0px 10px;
|
||||
padding: 0px 15px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
|
||||
font-size: 20px;
|
||||
}
|
||||
|
||||
|
||||
#battery {
|
||||
background-color: @joksi-bg;
|
||||
color: #EC5F67;
|
||||
border-radius: 0px 10px 10px 0px;
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 7px 0px 10px 0px;
|
||||
}
|
||||
|
||||
|
||||
#custom-clock {
|
||||
color: @joksi-bg;
|
||||
background-color: #98BE65;
|
||||
font-size: 20px;
|
||||
border-bottom: 2px solid #98BE65;
|
||||
border-radius: 0px;
|
||||
padding: 0px 15px 0px 10px;
|
||||
margin: 7px 0px 10px 10px;
|
||||
}
|
||||
|
||||
#clock {
|
||||
padding: 0px 10px 0px 10px;
|
||||
margin: 10px 5px 10px 5px;
|
||||
color: #98BE65;
|
||||
border-bottom: 2px solid #98BE65;
|
||||
border-radius: 8px;
|
||||
background: #141414;
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,300 +0,0 @@
|
|||
# A TOML linter such as https://taplo.tamasfe.dev/ can use this schema to validate your config.
|
||||
# If you encounter any issues, please make an issue at https://github.com/yazi-rs/schemas.
|
||||
"$schema" = "https://yazi-rs.github.io/schemas/keymap.json"
|
||||
|
||||
[manager]
|
||||
|
||||
keymap = [
|
||||
{ on = [ "<Esc>" ], exec = "escape", desc = "Exit visual mode, clear selected, or cancel search" },
|
||||
{ on = [ "q" ], exec = "quit", desc = "Exit the process" },
|
||||
{ on = [ "Q" ], exec = "quit --no-cwd-file", desc = "Exit the process without writing cwd-file" },
|
||||
{ on = [ "<C-q>" ], exec = "close", desc = "Close the current tab, or quit if it is last tab" },
|
||||
{ on = [ "<C-z>" ], exec = "suspend", desc = "Suspend the process" },
|
||||
|
||||
# Navigation
|
||||
{ on = [ "k" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "j" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "K" ], exec = "arrow -5", desc = "Move cursor up 5 lines" },
|
||||
{ on = [ "J" ], exec = "arrow 5", desc = "Move cursor down 5 lines" },
|
||||
|
||||
{ on = [ "<S-Up>" ], exec = "arrow -5", desc = "Move cursor up 5 lines" },
|
||||
{ on = [ "<S-Down>" ], exec = "arrow 5", desc = "Move cursor down 5 lines" },
|
||||
|
||||
{ on = [ "<C-u>" ], exec = "arrow -50%", desc = "Move cursor up half page" },
|
||||
{ on = [ "<C-d>" ], exec = "arrow 50%", desc = "Move cursor down half page" },
|
||||
{ on = [ "<C-b>" ], exec = "arrow -100%", desc = "Move cursor up one page" },
|
||||
{ on = [ "<C-f>" ], exec = "arrow 100%", desc = "Move cursor down one page" },
|
||||
|
||||
{ on = [ "<C-PageUp>" ], exec = "arrow -50%", desc = "Move cursor up half page" },
|
||||
{ on = [ "<C-PageDown>" ], exec = "arrow 50%", desc = "Move cursor down half page" },
|
||||
{ on = [ "<PageUp>" ], exec = "arrow -100%", desc = "Move cursor up one page" },
|
||||
{ on = [ "<PageDown>" ], exec = "arrow 100%", desc = "Move cursor down one page" },
|
||||
|
||||
{ on = [ "h" ], exec = [ "escape --visual", "leave" ], desc = "Go back to the parent directory" },
|
||||
{ on = [ "l" ], exec = [ "escape --visual", "enter" ], desc = "Enter the child directory" },
|
||||
|
||||
{ on = [ "H" ], exec = "back", desc = "Go back to the previous directory" },
|
||||
{ on = [ "L" ], exec = "forward", desc = "Go forward to the next directory" },
|
||||
|
||||
{ on = [ "<A-k>" ], exec = "seek -5", desc = "Seek up 5 units in the preview" },
|
||||
{ on = [ "<A-j>" ], exec = "seek 5", desc = "Seek down 5 units in the preview" },
|
||||
{ on = [ "<A-PageUp>" ], exec = "seek -5", desc = "Seek up 5 units in the preview" },
|
||||
{ on = [ "<A-PageDown>" ], exec = "seek 5", desc = "Seek down 5 units in the preview" },
|
||||
|
||||
{ on = [ "<Up>" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "<Down>" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
{ on = [ "<Left>" ], exec = "leave", desc = "Go back to the parent directory" },
|
||||
{ on = [ "<Right>" ], exec = "enter", desc = "Enter the child directory" },
|
||||
|
||||
{ on = [ "g", "g" ], exec = "arrow -99999999", desc = "Move cursor to the top" },
|
||||
{ on = [ "G" ], exec = "arrow 99999999", desc = "Move cursor to the bottom" },
|
||||
|
||||
# Selection
|
||||
{ on = [ "<Space>" ], exec = [ "select --state=none", "arrow 1" ], desc = "Toggle the current selection state" },
|
||||
{ on = [ "v" ], exec = "visual_mode", desc = "Enter visual mode (selection mode)" },
|
||||
{ on = [ "V" ], exec = "visual_mode --unset", desc = "Enter visual mode (unset mode)" },
|
||||
{ on = [ "<C-a>" ], exec = "select_all --state=true", desc = "Select all files" },
|
||||
{ on = [ "<C-r>" ], exec = "select_all --state=none", desc = "Inverse selection of all files" },
|
||||
|
||||
# Operation
|
||||
{ on = [ "o" ], exec = [ "escape --visual", "open" ], desc = "Open the selected files" },
|
||||
{ on = [ "O" ], exec = [ "escape --visual", "open --interactive" ], desc = "Open the selected files interactively" },
|
||||
{ on = [ "<Enter>" ], exec = [ "escape --visual", "open" ], desc = "Open the selected files" },
|
||||
{ on = [ "<C-Enter>" ], exec = [ "escape --visual", "open --interactive" ], desc = "Open the selected files interactively" },
|
||||
{ on = [ "y" ], exec = [ "escape --visual", "yank" ], desc = "Copy the selected files" },
|
||||
{ on = [ "Y" ], exec = "unyank", desc = "Cancel the yank status of files" },
|
||||
{ on = [ "x" ], exec = [ "escape --visual", "yank --cut" ], desc = "Cut the selected files" },
|
||||
{ on = [ "p" ], exec = "paste", desc = "Paste the files" },
|
||||
{ on = [ "P" ], exec = "paste --force", desc = "Paste the files (overwrite if the destination exists)" },
|
||||
{ on = [ "-" ], exec = "link", desc = "Symlink the absolute path of files" },
|
||||
{ on = [ "_" ], exec = "link --relative", desc = "Symlink the relative path of files" },
|
||||
{ on = [ "d" ], exec = [ "escape --visual", "remove --permanently" ], desc = "Permanently delete the files" },
|
||||
{ on = [ "D" ], exec = [ "escape --visual", "remove --permanently" ], desc = "Permanently delete the files" },
|
||||
{ on = [ "a" ], exec = "create", desc = "Create a file or directory (ends with / for directories)" },
|
||||
{ on = [ "r" ], exec = [ "escape --visual", "rename --cursor=before_ext" ], desc = "Rename a file or directory" },
|
||||
{ on = [ ";" ], exec = [ "escape --visual", "shell" ], desc = "Run a shell command" },
|
||||
{ on = [ ":" ], exec = [ "escape --visual", "shell --block" ], desc = "Run a shell command (block the UI until the command finishes)" },
|
||||
{ on = [ "." ], exec = "hidden toggle", desc = "Toggle the visibility of hidden files" },
|
||||
{ on = [ "s" ], exec = "search fd", desc = "Search files by name using fd" },
|
||||
{ on = [ "S" ], exec = "search rg", desc = "Search files by content using ripgrep" },
|
||||
{ on = [ "<C-s>" ], exec = "search none", desc = "Cancel the ongoing search" },
|
||||
{ on = [ "z" ], exec = "jump zoxide", desc = "Jump to a directory using zoxide" },
|
||||
{ on = [ "Z" ], exec = "jump fzf", desc = "Jump to a directory, or reveal a file using fzf" },
|
||||
|
||||
# Linemode
|
||||
{ on = [ "m", "s" ], exec = "linemode size", desc = "Set linemode to size" },
|
||||
{ on = [ "m", "p" ], exec = "linemode permissions", desc = "Set linemode to permissions" },
|
||||
{ on = [ "m", "m" ], exec = "linemode mtime", desc = "Set linemode to mtime" },
|
||||
{ on = [ "m", "n" ], exec = "linemode none", desc = "Set linemode to none" },
|
||||
|
||||
# Copy
|
||||
{ on = [ "c", "c" ], exec = [ "escape --visual", "copy path" ], desc = "Copy the absolute path" },
|
||||
{ on = [ "c", "d" ], exec = [ "escape --visual", "copy dirname" ], desc = "Copy the path of the parent directory" },
|
||||
{ on = [ "c", "f" ], exec = [ "escape --visual", "copy filename" ], desc = "Copy the name of the file" },
|
||||
{ on = [ "c", "n" ], exec = [ "escape --visual", "copy name_without_ext" ], desc = "Copy the name of the file without the extension" },
|
||||
|
||||
# Filter
|
||||
{ on = [ "f" ], exec = "filter --smart", desc = "Filter the files" },
|
||||
|
||||
# Find
|
||||
{ on = [ "/" ], exec = "find --smart", desc = "Find next file" },
|
||||
{ on = [ "?" ], exec = "find --previous --smart", desc = "Find previous file" },
|
||||
{ on = [ "n" ], exec = "find_arrow", desc = "Go to next found file" },
|
||||
{ on = [ "N" ], exec = "find_arrow --previous", desc = "Go to previous found file" },
|
||||
|
||||
# Sorting
|
||||
{ on = [ ",", "m" ], exec = "sort modified --dir-first", desc = "Sort by modified time" },
|
||||
{ on = [ ",", "M" ], exec = "sort modified --reverse --dir-first", desc = "Sort by modified time (reverse)" },
|
||||
{ on = [ ",", "c" ], exec = "sort created --dir-first", desc = "Sort by created time" },
|
||||
{ on = [ ",", "C" ], exec = "sort created --reverse --dir-first", desc = "Sort by created time (reverse)" },
|
||||
{ on = [ ",", "e" ], exec = "sort extension --dir-first", desc = "Sort by extension" },
|
||||
{ on = [ ",", "E" ], exec = "sort extension --reverse --dir-first", desc = "Sort by extension (reverse)" },
|
||||
{ on = [ ",", "a" ], exec = "sort alphabetical --dir-first", desc = "Sort alphabetically" },
|
||||
{ on = [ ",", "A" ], exec = "sort alphabetical --reverse --dir-first", desc = "Sort alphabetically (reverse)" },
|
||||
{ on = [ ",", "n" ], exec = "sort natural --dir-first", desc = "Sort naturally" },
|
||||
{ on = [ ",", "N" ], exec = "sort natural --reverse --dir-first", desc = "Sort naturally (reverse)" },
|
||||
{ on = [ ",", "s" ], exec = "sort size --dir-first", desc = "Sort by size" },
|
||||
{ on = [ ",", "S" ], exec = "sort size --reverse --dir-first", desc = "Sort by size (reverse)" },
|
||||
|
||||
# Tabs
|
||||
{ on = [ "t" ], exec = "tab_create --current", desc = "Create a new tab using the current path" },
|
||||
|
||||
{ on = [ "1" ], exec = "tab_switch 0", desc = "Switch to the first tab" },
|
||||
{ on = [ "2" ], exec = "tab_switch 1", desc = "Switch to the second tab" },
|
||||
{ on = [ "3" ], exec = "tab_switch 2", desc = "Switch to the third tab" },
|
||||
{ on = [ "4" ], exec = "tab_switch 3", desc = "Switch to the fourth tab" },
|
||||
{ on = [ "5" ], exec = "tab_switch 4", desc = "Switch to the fifth tab" },
|
||||
{ on = [ "6" ], exec = "tab_switch 5", desc = "Switch to the sixth tab" },
|
||||
{ on = [ "7" ], exec = "tab_switch 6", desc = "Switch to the seventh tab" },
|
||||
{ on = [ "8" ], exec = "tab_switch 7", desc = "Switch to the eighth tab" },
|
||||
{ on = [ "9" ], exec = "tab_switch 8", desc = "Switch to the ninth tab" },
|
||||
|
||||
{ on = [ "[" ], exec = "tab_switch -1 --relative", desc = "Switch to the previous tab" },
|
||||
{ on = [ "]" ], exec = "tab_switch 1 --relative", desc = "Switch to the next tab" },
|
||||
|
||||
{ on = [ "{" ], exec = "tab_swap -1", desc = "Swap the current tab with the previous tab" },
|
||||
{ on = [ "}" ], exec = "tab_swap 1", desc = "Swap the current tab with the next tab" },
|
||||
|
||||
# Tasks
|
||||
{ on = [ "w" ], exec = "tasks_show", desc = "Show the tasks manager" },
|
||||
|
||||
# Goto
|
||||
{ on = [ "g", "h" ], exec = "cd ~", desc = "Go to the home directory" },
|
||||
{ on = [ "g", "c" ], exec = "cd ~/.config", desc = "Go to the config directory" },
|
||||
{ on = [ "g", "d" ], exec = "cd ~/Downloads", desc = "Go to the downloads directory" },
|
||||
{ on = [ "g", "t" ], exec = "cd /tmp", desc = "Go to the temporary directory" },
|
||||
{ on = [ "g", "<Space>" ], exec = "cd --interactive", desc = "Go to a directory interactively" },
|
||||
|
||||
# Help
|
||||
{ on = [ "~" ], exec = "help", desc = "Open help" },
|
||||
]
|
||||
|
||||
[tasks]
|
||||
|
||||
keymap = [
|
||||
{ on = [ "<Esc>" ], exec = "close", desc = "Hide the task manager" },
|
||||
{ on = [ "<C-q>" ], exec = "close", desc = "Hide the task manager" },
|
||||
{ on = [ "w" ], exec = "close", desc = "Hide the task manager" },
|
||||
|
||||
{ on = [ "k" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "j" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "<Up>" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "<Down>" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "<Enter>" ], exec = "inspect", desc = "Inspect the task" },
|
||||
{ on = [ "x" ], exec = "cancel", desc = "Cancel the task" },
|
||||
|
||||
{ on = [ "~" ], exec = "help", desc = "Open help" }
|
||||
]
|
||||
|
||||
[select]
|
||||
|
||||
keymap = [
|
||||
{ on = [ "<C-q>" ], exec = "close", desc = "Cancel selection" },
|
||||
{ on = [ "<Esc>" ], exec = "close", desc = "Cancel selection" },
|
||||
{ on = [ "<Enter>" ], exec = "close --submit", desc = "Submit the selection" },
|
||||
|
||||
{ on = [ "k" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "j" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "K" ], exec = "arrow -5", desc = "Move cursor up 5 lines" },
|
||||
{ on = [ "J" ], exec = "arrow 5", desc = "Move cursor down 5 lines" },
|
||||
|
||||
{ on = [ "<Up>" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "<Down>" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "<S-Up>" ], exec = "arrow -5", desc = "Move cursor up 5 lines" },
|
||||
{ on = [ "<S-Down>" ], exec = "arrow 5", desc = "Move cursor down 5 lines" },
|
||||
|
||||
{ on = [ "~" ], exec = "help", desc = "Open help" }
|
||||
]
|
||||
|
||||
[input]
|
||||
|
||||
keymap = [
|
||||
{ on = [ "<C-q>" ], exec = "close", desc = "Cancel input" },
|
||||
{ on = [ "<Enter>" ], exec = "close --submit", desc = "Submit the input" },
|
||||
{ on = [ "<Esc>" ], exec = "escape", desc = "Go back the normal mode, or cancel input" },
|
||||
|
||||
# Mode
|
||||
{ on = [ "i" ], exec = "insert", desc = "Enter insert mode" },
|
||||
{ on = [ "a" ], exec = "insert --append", desc = "Enter append mode" },
|
||||
{ on = [ "I" ], exec = [ "move -999", "insert" ], desc = "Move to the BOL, and enter insert mode" },
|
||||
{ on = [ "A" ], exec = [ "move 999", "insert --append" ], desc = "Move to the EOL, and enter append mode" },
|
||||
{ on = [ "v" ], exec = "visual", desc = "Enter visual mode" },
|
||||
{ on = [ "V" ], exec = [ "move -999", "visual", "move 999" ], desc = "Enter visual mode and select all" },
|
||||
|
||||
# Character-wise movement
|
||||
{ on = [ "h" ], exec = "move -1", desc = "Move back a character" },
|
||||
{ on = [ "l" ], exec = "move 1", desc = "Move forward a character" },
|
||||
{ on = [ "<Left>" ], exec = "move -1", desc = "Move back a character" },
|
||||
{ on = [ "<Right>" ], exec = "move 1", desc = "Move forward a character" },
|
||||
{ on = [ "<C-b>" ], exec = "move -1", desc = "Move back a character" },
|
||||
{ on = [ "<C-f>" ], exec = "move 1", desc = "Move forward a character" },
|
||||
|
||||
# Word-wise movement
|
||||
{ on = [ "b" ], exec = "backward", desc = "Move back to the start of the current or previous word" },
|
||||
{ on = [ "w" ], exec = "forward", desc = "Move forward to the start of the next word" },
|
||||
{ on = [ "e" ], exec = "forward --end-of-word", desc = "Move forward to the end of the current or next word" },
|
||||
{ on = [ "<A-b>" ], exec = "backward", desc = "Move back to the start of the current or previous word" },
|
||||
{ on = [ "<A-f>" ], exec = "forward --end-of-word", desc = "Move forward to the end of the current or next word" },
|
||||
|
||||
# Line-wise movement
|
||||
{ on = [ "0" ], exec = "move -999", desc = "Move to the BOL" },
|
||||
{ on = [ "$" ], exec = "move 999", desc = "Move to the EOL" },
|
||||
{ on = [ "<C-a>" ], exec = "move -999", desc = "Move to the BOL" },
|
||||
{ on = [ "<C-e>" ], exec = "move 999", desc = "Move to the EOL" },
|
||||
{ on = [ "<Home>" ], exec = "move -999", desc = "Move to the BOL" },
|
||||
{ on = [ "<End>" ], exec = "move 999", desc = "Move to the EOL" },
|
||||
|
||||
# Delete
|
||||
{ on = [ "<Backspace>" ], exec = "backspace", desc = "Delete the character before the cursor" },
|
||||
{ on = [ "<Delete>" ], exec = "backspace --under", desc = "Delete the character under the cursor" },
|
||||
{ on = [ "<C-h>" ], exec = "backspace", desc = "Delete the character before the cursor" },
|
||||
{ on = [ "<C-d>" ], exec = "backspace --under", desc = "Delete the character under the cursor" },
|
||||
|
||||
# Kill
|
||||
{ on = [ "<C-u>" ], exec = "kill bol", desc = "Kill backwards to the BOL" },
|
||||
{ on = [ "<C-k>" ], exec = "kill eol", desc = "Kill forwards to the EOL" },
|
||||
{ on = [ "<C-w>" ], exec = "kill backward", desc = "Kill backwards to the start of the current word" },
|
||||
{ on = [ "<A-d>" ], exec = "kill forward", desc = "Kill forwards to the end of the current word" },
|
||||
|
||||
# Cut/Yank/Paste
|
||||
{ on = [ "d" ], exec = "delete --cut", desc = "Cut the selected characters" },
|
||||
{ on = [ "D" ], exec = [ "delete --cut", "move 999" ], desc = "Cut until the EOL" },
|
||||
{ on = [ "c" ], exec = "delete --cut --insert", desc = "Cut the selected characters, and enter insert mode" },
|
||||
{ on = [ "C" ], exec = [ "delete --cut --insert", "move 999" ], desc = "Cut until the EOL, and enter insert mode" },
|
||||
{ on = [ "x" ], exec = [ "delete --cut", "move 1 --in-operating" ], desc = "Cut the current character" },
|
||||
{ on = [ "y" ], exec = "yank", desc = "Copy the selected characters" },
|
||||
{ on = [ "p" ], exec = "paste", desc = "Paste the copied characters after the cursor" },
|
||||
{ on = [ "P" ], exec = "paste --before", desc = "Paste the copied characters before the cursor" },
|
||||
|
||||
# Undo/Redo
|
||||
{ on = [ "u" ], exec = "undo", desc = "Undo the last operation" },
|
||||
{ on = [ "<C-r>" ], exec = "redo", desc = "Redo the last operation" },
|
||||
|
||||
# Help
|
||||
{ on = [ "~" ], exec = "help", desc = "Open help" }
|
||||
]
|
||||
|
||||
[completion]
|
||||
|
||||
keymap = [
|
||||
{ on = [ "<C-q>" ], exec = "close", desc = "Cancel completion" },
|
||||
{ on = [ "<Tab>" ], exec = "close --submit", desc = "Submit the completion" },
|
||||
{ on = [ "<Enter>" ], exec = [ "close --submit", "close_input --submit" ], desc = "Submit the completion and input" },
|
||||
|
||||
{ on = [ "<A-k>" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "<A-j>" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "<Up>" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "<Down>" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "~" ], exec = "help", desc = "Open help" }
|
||||
]
|
||||
|
||||
[help]
|
||||
|
||||
keymap = [
|
||||
{ on = [ "<Esc>" ], exec = "escape", desc = "Clear the filter, or hide the help" },
|
||||
{ on = [ "q" ], exec = "close", desc = "Exit the process" },
|
||||
{ on = [ "<C-q>" ], exec = "close", desc = "Hide the help" },
|
||||
|
||||
# Navigation
|
||||
{ on = [ "k" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "j" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "K" ], exec = "arrow -5", desc = "Move cursor up 5 lines" },
|
||||
{ on = [ "J" ], exec = "arrow 5", desc = "Move cursor down 5 lines" },
|
||||
|
||||
{ on = [ "<Up>" ], exec = "arrow -1", desc = "Move cursor up" },
|
||||
{ on = [ "<Down>" ], exec = "arrow 1", desc = "Move cursor down" },
|
||||
|
||||
{ on = [ "<S-Up>" ], exec = "arrow -5", desc = "Move cursor up 5 lines" },
|
||||
{ on = [ "<S-Down>" ], exec = "arrow 5", desc = "Move cursor down 5 lines" },
|
||||
|
||||
# Filtering
|
||||
{ on = [ "/" ], exec = "filter", desc = "Apply a filter for the help items" },
|
||||
]
|
|
@ -1,145 +0,0 @@
|
|||
# vim:fileencoding=utf-8:foldmethod=marker
|
||||
|
||||
# : Manager {{{
|
||||
|
||||
[manager]
|
||||
cwd = { fg = "#81c8be" }
|
||||
|
||||
# Hovered
|
||||
hovered = { fg = "#303446", bg = "#8caaee" }
|
||||
preview_hovered = { underline = true }
|
||||
|
||||
# Find
|
||||
find_keyword = { fg = "#e5c890", italic = true }
|
||||
find_position = { fg = "#f4b8e4", bg = "reset", italic = true }
|
||||
|
||||
# Marker
|
||||
marker_selected = { fg = "#a6d189", bg = "#a6d189" }
|
||||
marker_copied = { fg = "#e5c890", bg = "#e5c890" }
|
||||
marker_cut = { fg = "#e78284", bg = "#e78284" }
|
||||
|
||||
# Tab
|
||||
tab_active = { fg = "#303446", bg = "#8caaee" }
|
||||
tab_inactive = { fg = "#c6d0f5", bg = "#51576d" }
|
||||
tab_width = 1
|
||||
|
||||
# Border
|
||||
border_symbol = "│"
|
||||
border_style = { fg = "#838ba7" }
|
||||
|
||||
# Highlighting
|
||||
syntect_theme = "~/.config/yazi/Catppuccin-frappe.tmTheme"
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : Status {{{
|
||||
|
||||
[status]
|
||||
separator_open = ""
|
||||
separator_close = ""
|
||||
separator_style = { fg = "#51576d", bg = "#51576d" }
|
||||
|
||||
# Mode
|
||||
mode_normal = { fg = "#303446", bg = "#8caaee", bold = true }
|
||||
mode_select = { fg = "#303446", bg = "#a6d189", bold = true }
|
||||
mode_unset = { fg = "#303446", bg = "#eebebe", bold = true }
|
||||
|
||||
# Progress
|
||||
progress_label = { fg = "#ffffff", bold = true }
|
||||
progress_normal = { fg = "#8caaee", bg = "#51576d" }
|
||||
progress_error = { fg = "#e78284", bg = "#51576d" }
|
||||
|
||||
# Permissions
|
||||
permissions_t = { fg = "#8caaee" }
|
||||
permissions_r = { fg = "#e5c890" }
|
||||
permissions_w = { fg = "#e78284" }
|
||||
permissions_x = { fg = "#a6d189" }
|
||||
permissions_s = { fg = "#838ba7" }
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : Input {{{
|
||||
|
||||
[input]
|
||||
border = { fg = "#8caaee" }
|
||||
title = {}
|
||||
value = {}
|
||||
selected = { reversed = true }
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : Select {{{
|
||||
|
||||
[select]
|
||||
border = { fg = "#8caaee" }
|
||||
active = { fg = "#f4b8e4" }
|
||||
inactive = {}
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : Tasks {{{
|
||||
|
||||
[tasks]
|
||||
border = { fg = "#8caaee" }
|
||||
title = {}
|
||||
hovered = { underline = true }
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : Which {{{
|
||||
|
||||
[which]
|
||||
mask = { bg = "#414559" }
|
||||
cand = { fg = "#81c8be" }
|
||||
rest = { fg = "#949cbb" }
|
||||
desc = { fg = "#f4b8e4" }
|
||||
separator = " "
|
||||
separator_style = { fg = "#626880" }
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : Help {{{
|
||||
|
||||
[help]
|
||||
on = { fg = "#f4b8e4" }
|
||||
exec = { fg = "#81c8be" }
|
||||
desc = { fg = "#949cbb" }
|
||||
hovered = { bg = "#626880", bold = true }
|
||||
footer = { fg = "#51576d", bg = "#c6d0f5" }
|
||||
|
||||
# : }}}
|
||||
|
||||
|
||||
# : File-specific styles {{{
|
||||
|
||||
[filetype]
|
||||
|
||||
rules = [
|
||||
# Images
|
||||
{ mime = "image/*", fg = "#81c8be" },
|
||||
|
||||
# Videos
|
||||
{ mime = "video/*", fg = "#e5c890" },
|
||||
{ mime = "audio/*", fg = "#e5c890" },
|
||||
|
||||
# Archives
|
||||
{ mime = "application/zip", fg = "#f4b8e4" },
|
||||
{ mime = "application/gzip", fg = "#f4b8e4" },
|
||||
{ mime = "application/x-tar", fg = "#f4b8e4" },
|
||||
{ mime = "application/x-bzip", fg = "#f4b8e4" },
|
||||
{ mime = "application/x-bzip2", fg = "#f4b8e4" },
|
||||
{ mime = "application/x-7z-compressed", fg = "#f4b8e4" },
|
||||
{ mime = "application/x-rar", fg = "#f4b8e4" },
|
||||
|
||||
# Fallback
|
||||
{ name = "*", fg = "#c6d0f5" },
|
||||
{ name = "*/", fg = "#8caaee" }
|
||||
]
|
||||
|
||||
# : }}}
|
202
.config/yazi/yazi.toml
Executable file → Normal file
202
.config/yazi/yazi.toml
Executable file → Normal file
|
@ -3,21 +3,26 @@
|
|||
"$schema" = "https://yazi-rs.github.io/schemas/yazi.json"
|
||||
|
||||
[manager]
|
||||
ratio = [ 1, 2, 3 ]
|
||||
ratio = [ 1, 4, 3 ]
|
||||
sort_by = "alphabetical"
|
||||
sort_sensitive = true
|
||||
sort_sensitive = false
|
||||
sort_reverse = false
|
||||
sort_dir_first = true
|
||||
linemode = "size"
|
||||
sort_translit = false
|
||||
linemode = "none"
|
||||
show_hidden = false
|
||||
show_symlink = true
|
||||
scrolloff = 5
|
||||
mouse_events = [ "click", "scroll" ]
|
||||
title_format = "Yazi: {cwd}"
|
||||
|
||||
[preview]
|
||||
tab_size = 4
|
||||
max_width = 900
|
||||
wrap = "no"
|
||||
tab_size = 2
|
||||
max_width = 600
|
||||
max_height = 900
|
||||
cache_dir = ""
|
||||
image_delay = 30
|
||||
image_filter = "triangle"
|
||||
image_quality = 75
|
||||
sixel_fraction = 15
|
||||
|
@ -26,116 +31,132 @@ ueberzug_offset = [ 0, 0, 0, 0 ]
|
|||
|
||||
[opener]
|
||||
edit = [
|
||||
{ exec = '${EDITOR:=nvim} "$@"', desc = "$EDITOR", block = true, for = "unix" },
|
||||
{ exec = 'code "%*"', orphan = true, for = "windows" },
|
||||
{ run = '${EDITOR:-vi} "$@"', desc = "$EDITOR", block = true, for = "unix" },
|
||||
{ run = 'code %*', orphan = true, desc = "code", for = "windows" },
|
||||
{ run = 'code -w %*', block = true, desc = "code (block)", for = "windows" },
|
||||
]
|
||||
open = [
|
||||
{ exec = 'xdg-open "$@"', desc = "Open", for = "linux" },
|
||||
{ exec = 'open "$@"', desc = "Open", for = "macos" },
|
||||
{ exec = 'start "" "%1"', orphan = true, desc = "Open", for = "windows" }
|
||||
{ run = 'xdg-open "$1"', desc = "Open", for = "linux" },
|
||||
{ run = 'open "$@"', desc = "Open", for = "macos" },
|
||||
{ run = 'start "" "%1"', orphan = true, desc = "Open", for = "windows" },
|
||||
]
|
||||
reveal = [
|
||||
{ exec = 'open -R "$1"', desc = "Reveal", for = "macos" },
|
||||
{ exec = 'explorer /select, "%1"', orphan = true, desc = "Reveal", for = "windows" },
|
||||
{ exec = '''exiftool "$1"; echo "Press enter to exit"; read''', block = true, desc = "Show EXIF", for = "unix" },
|
||||
{ run = 'xdg-open "$(dirname "$1")"', desc = "Reveal", for = "linux" },
|
||||
{ run = 'open -R "$1"', desc = "Reveal", for = "macos" },
|
||||
{ run = 'explorer /select,"%1"', orphan = true, desc = "Reveal", for = "windows" },
|
||||
{ run = '''exiftool "$1"; echo "Press enter to exit"; read _''', block = true, desc = "Show EXIF", for = "unix" },
|
||||
]
|
||||
extract = [
|
||||
{ exec = 'unar "$1"', desc = "Extract here", for = "unix" },
|
||||
{ exec = 'unar "%1"', desc = "Extract here", for = "windows" },
|
||||
{ run = 'ya pub extract --list "$@"', desc = "Extract here", for = "unix" },
|
||||
{ run = 'ya pub extract --list %*', desc = "Extract here", for = "windows" },
|
||||
]
|
||||
play = [
|
||||
{ exec = 'mpv "$@"', orphan = true, for = "unix" },
|
||||
{ exec = 'mpv "%1"', orphan = true, for = "windows" },
|
||||
{ exec = '''mediainfo "$1"; echo "Press enter to exit"; read''', block = true, desc = "Show media info", for = "unix" },
|
||||
{ run = 'mpv --force-window "$@"', orphan = true, for = "unix" },
|
||||
{ run = 'mpv --force-window %*', orphan = true, for = "windows" },
|
||||
{ run = '''mediainfo "$1"; echo "Press enter to exit"; read _''', block = true, desc = "Show media info", for = "unix" },
|
||||
]
|
||||
imv = [ { exec = 'imv "$@"', orphan = true, for = "unix"} ]
|
||||
zathura = [ { exec = 'zathura "$@"', orphan = true, for = "unix"} ]
|
||||
|
||||
[open]
|
||||
rules = [
|
||||
# Folder
|
||||
{ name = "*/", use = [ "edit", "open", "reveal" ] },
|
||||
|
||||
# Text
|
||||
{ mime = "text/*", use = [ "edit", "reveal" ] },
|
||||
{ mime = "image/vnd.djvu", use = [ "zathura" ] },
|
||||
{ mime = "image/vnd.djvu+multipage", use = [ "zathura" ] },
|
||||
{ mime = "image/*", use = [ "imv" ] },
|
||||
{ mime = "video/*", use = [ "play", "reveal" ] },
|
||||
{ mime = "audio/*", use = [ "play", "reveal" ] },
|
||||
{ mime = "inode/x-empty", use = [ "edit", "reveal" ] },
|
||||
|
||||
{ mime = "application/json", use = [ "edit", "reveal" ] },
|
||||
{ mime = "application/pdf", use = [ "zathura" ] },
|
||||
# Image
|
||||
{ mime = "image/*", use = [ "open", "reveal" ] },
|
||||
# Media
|
||||
{ mime = "{audio,video}/*", use = [ "play", "reveal" ] },
|
||||
# Archive
|
||||
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", use = [ "extract", "reveal" ] },
|
||||
# JSON
|
||||
{ mime = "application/{json,ndjson}", use = [ "edit", "reveal" ] },
|
||||
{ mime = "*/javascript", use = [ "edit", "reveal" ] },
|
||||
|
||||
{ mime = "application/zip", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/gzip", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/x-tar", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/x-bzip", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/x-bzip2", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/x-7z-compressed", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/x-rar", use = [ "extract", "reveal" ] },
|
||||
{ mime = "application/xz", use = [ "extract", "reveal" ] },
|
||||
|
||||
{ mime = "*", use = [ "open", "reveal" ] },
|
||||
# Empty file
|
||||
{ mime = "inode/empty", use = [ "edit", "reveal" ] },
|
||||
# Fallback
|
||||
{ name = "*", use = [ "open", "reveal" ] },
|
||||
]
|
||||
|
||||
[tasks]
|
||||
micro_workers = 20
|
||||
macro_workers = 40
|
||||
bizarre_retry = 5
|
||||
micro_workers = 10
|
||||
macro_workers = 10
|
||||
bizarre_retry = 3
|
||||
image_alloc = 536870912 # 512MB
|
||||
image_bound = [ 0, 0 ]
|
||||
suppress_preload = false
|
||||
|
||||
[plugin]
|
||||
|
||||
preloaders = [
|
||||
{ name = "*", cond = "!mime", exec = "mime", multi = true, prio = "high" },
|
||||
fetchers = [
|
||||
# Mimetype
|
||||
{ id = "mime", name = "*", run = "mime", if = "!mime", prio = "high" },
|
||||
]
|
||||
spotters = [
|
||||
{ name = "*/", run = "folder" },
|
||||
# Code
|
||||
{ mime = "text/*", run = "code" },
|
||||
{ mime = "*/{xml,javascript,wine-extension-ini}", run = "code" },
|
||||
# Image
|
||||
{ mime = "image/vnd.djvu", exec = "noop" },
|
||||
{ mime = "image/*", exec = "image" },
|
||||
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
|
||||
{ mime = "image/*", run = "image" },
|
||||
# Video
|
||||
{ mime = "video/*", exec = "video" },
|
||||
{ mime = "video/*", run = "video" },
|
||||
# Fallback
|
||||
{ name = "*", run = "file" },
|
||||
]
|
||||
preloaders = [
|
||||
# Image
|
||||
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
|
||||
{ mime = "image/*", run = "image" },
|
||||
# Video
|
||||
{ mime = "video/*", run = "video" },
|
||||
# PDF
|
||||
{ mime = "application/pdf", exec = "pdf" },
|
||||
{ mime = "application/pdf", run = "pdf" },
|
||||
# Font
|
||||
{ mime = "font/*", run = "font" },
|
||||
{ mime = "application/ms-opentype", run = "font" },
|
||||
]
|
||||
previewers = [
|
||||
{ name = "*/", exec = "folder", sync = true },
|
||||
{ name = "*/", run = "folder", sync = true },
|
||||
# Code
|
||||
{ mime = "text/*", exec = "code" },
|
||||
{ mime = "*/xml", exec = "code" },
|
||||
{ mime = "*/javascript", exec = "code" },
|
||||
{ mime = "*/x-wine-extension-ini", exec = "code" },
|
||||
{ mime = "text/*", run = "code" },
|
||||
{ mime = "*/{xml,javascript,wine-extension-ini}", run = "code" },
|
||||
# JSON
|
||||
{ mime = "application/json", exec = "json" },
|
||||
{ mime = "application/{json,ndjson}", run = "json" },
|
||||
# Image
|
||||
{ mime = "image/vnd.djvu", exec = "noop" },
|
||||
{ mime = "image/*", exec = "image" },
|
||||
{ mime = "image/{avif,hei?,jxl,svg+xml}", run = "magick" },
|
||||
{ mime = "image/*", run = "image" },
|
||||
# Video
|
||||
{ mime = "video/*", exec = "video" },
|
||||
{ mime = "video/*", run = "video" },
|
||||
# PDF
|
||||
{ mime = "application/pdf", exec = "pdf" },
|
||||
{ mime = "application/pdf", run = "pdf" },
|
||||
# Archive
|
||||
{ mime = "application/zip", exec = "archive" },
|
||||
{ mime = "application/gzip", exec = "archive" },
|
||||
{ mime = "application/x-tar", exec = "archive" },
|
||||
{ mime = "application/x-bzip", exec = "archive" },
|
||||
{ mime = "application/x-bzip2", exec = "archive" },
|
||||
{ mime = "application/x-7z-compressed", exec = "archive" },
|
||||
{ mime = "application/x-rar", exec = "archive" },
|
||||
{ mime = "application/xz", exec = "archive" },
|
||||
{ mime = "application/{zip,rar,7z*,tar,gzip,xz,zstd,bzip*,lzma,compress,archive,cpio,arj,xar,ms-cab*}", run = "archive" },
|
||||
{ mime = "application/{debian*-package,redhat-package-manager,rpm,android.package-archive}", run = "archive" },
|
||||
{ name = "*.{AppImage,appimage}", run = "archive" },
|
||||
# Virtual Disk / Disk Image
|
||||
{ mime = "application/{iso9660-image,qemu-disk,ms-wim,apple-diskimage}", run = "archive" },
|
||||
{ mime = "application/virtualbox-{vhd,vhdx}", run = "archive" },
|
||||
{ name = "*.{img,fat,ext,ext2,ext3,ext4,squashfs,ntfs,hfs,hfsx}", run = "archive" },
|
||||
# Font
|
||||
{ mime = "font/*", run = "font" },
|
||||
{ mime = "application/ms-opentype", run = "font" },
|
||||
# Empty file
|
||||
{ mime = "inode/empty", run = "empty" },
|
||||
# Fallback
|
||||
{ name = "*", exec = "file" },
|
||||
{ name = "*", run = "file" },
|
||||
]
|
||||
|
||||
[input]
|
||||
cursor_blink = false
|
||||
|
||||
# cd
|
||||
cd_title = "Change directory:"
|
||||
cd_origin = "top-center"
|
||||
cd_offset = [ 0, 2, 50, 3 ]
|
||||
|
||||
# create
|
||||
create_title = "Create:"
|
||||
create_title = [ "Create:", "Create (dir):" ]
|
||||
create_origin = "top-center"
|
||||
create_offset = [ 0, 2, 50, 3 ]
|
||||
|
||||
|
@ -144,16 +165,6 @@ rename_title = "Rename:"
|
|||
rename_origin = "hovered"
|
||||
rename_offset = [ 0, 1, 50, 3 ]
|
||||
|
||||
# trash
|
||||
trash_title = "Move {n} selected file{s} to trash? (y/N)"
|
||||
trash_origin = "top-center"
|
||||
trash_offset = [ 0, 2, 50, 3 ]
|
||||
|
||||
# delete
|
||||
delete_title = "Delete {n} selected file{s} permanently? (y/N)"
|
||||
delete_origin = "top-center"
|
||||
delete_offset = [ 0, 2, 50, 3 ]
|
||||
|
||||
# filter
|
||||
filter_title = "Filter:"
|
||||
filter_origin = "top-center"
|
||||
|
@ -174,17 +185,30 @@ shell_title = [ "Shell:", "Shell (block):" ]
|
|||
shell_origin = "top-center"
|
||||
shell_offset = [ 0, 2, 50, 3 ]
|
||||
|
||||
[confirm]
|
||||
# trash
|
||||
trash_title = "Trash {n} selected file{s}?"
|
||||
trash_origin = "center"
|
||||
trash_offset = [ 0, 0, 70, 20 ]
|
||||
|
||||
# delete
|
||||
delete_title = "Permanently delete {n} selected file{s}?"
|
||||
delete_origin = "center"
|
||||
delete_offset = [ 0, 0, 70, 20 ]
|
||||
|
||||
# overwrite
|
||||
overwrite_title = "Overwrite an existing file? (y/N)"
|
||||
overwrite_origin = "top-center"
|
||||
overwrite_offset = [ 0, 2, 50, 3 ]
|
||||
overwrite_title = "Overwrite file?"
|
||||
overwrite_content = "Will overwrite the following file:"
|
||||
overwrite_origin = "center"
|
||||
overwrite_offset = [ 0, 0, 50, 15 ]
|
||||
|
||||
# quit
|
||||
quit_title = "{n} task{s} running, sure to quit? (y/N)"
|
||||
quit_origin = "top-center"
|
||||
quit_offset = [ 0, 2, 50, 3 ]
|
||||
quit_title = "Quit?"
|
||||
quit_content = "The following task is still running, are you sure you want to quit?"
|
||||
quit_origin = "center"
|
||||
quit_offset = [ 0, 0, 50, 15 ]
|
||||
|
||||
[select]
|
||||
[pick]
|
||||
open_title = "Open with:"
|
||||
open_origin = "hovered"
|
||||
open_offset = [ 0, 1, 50, 7 ]
|
||||
|
@ -193,6 +217,4 @@ open_offset = [ 0, 1, 50, 7 ]
|
|||
sort_by = "none"
|
||||
sort_sensitive = false
|
||||
sort_reverse = false
|
||||
|
||||
[log]
|
||||
enabled = false
|
||||
sort_translit = false
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
abbr -g "aur"="sudo aura"
|
||||
abbr -g "aura"="sudo aura"
|
||||
abbr -g "cat"="bat"
|
||||
abbr -g "neo"="nvim +'Telescope oldfiles'"
|
||||
abbr -g "mann"="nvim +'Telescope man_pages'"
|
||||
|
|
|
@ -84,3 +84,10 @@
|
|||
|
||||
[rebase]
|
||||
updateRefs = true
|
||||
[init]
|
||||
defaultBranch = master
|
||||
[filter "lfs"]
|
||||
required = true
|
||||
clean = git-lfs clean -- %f
|
||||
smudge = git-lfs smudge -- %f
|
||||
process = git-lfs filter-process
|
||||
|
|
20
.mbsyncrc
Normal file
20
.mbsyncrc
Normal file
|
@ -0,0 +1,20 @@
|
|||
IMAPStore bonsai-remote
|
||||
Host mail.bonsai.cool
|
||||
Port 993
|
||||
User brk@bonsai.cool
|
||||
PassCmd "gopass show -o bonsai/mail"
|
||||
SSLType IMAPS
|
||||
CertificateFile /etc/ssl/certs/ca-certificates.crt
|
||||
|
||||
MaildirStore bonsai-local
|
||||
Path ~/mail/bonsai/
|
||||
Inbox ~/mail/bonsai/INBOX
|
||||
Subfolders Verbatim
|
||||
|
||||
Channel bonsai
|
||||
Far :bonsai-remote:
|
||||
Near :bonsai-local:
|
||||
Create Both
|
||||
Expunge Both
|
||||
Patterns % !Archive
|
||||
SyncState *
|
27
.zshrc
27
.zshrc
|
@ -95,6 +95,7 @@ compdef _directories md
|
|||
# Define aliases.
|
||||
alias tree='tree -a -I .git'
|
||||
alias ls='exa -1 --icons=always --group-directories-first'
|
||||
alias pacman='aura'
|
||||
# Add flags to existing aliases.
|
||||
|
||||
# Set shell options: http://zsh.sourceforge.net/Doc/Release/Options.html.
|
||||
|
@ -109,11 +110,23 @@ autoload -Uz compinit
|
|||
zstyle ':completion:*' menu select
|
||||
fpath+=~/.zfunc
|
||||
|
||||
kat="
|
||||
/l、
|
||||
(゚、 。 7
|
||||
l ~ヽ_
|
||||
じしf_,)ノ
|
||||
"
|
||||
# kat="
|
||||
# /l、
|
||||
# (゚、 。 7
|
||||
# l ~ヽ_
|
||||
# じしf_,)ノ
|
||||
# "
|
||||
#
|
||||
# printf $kat
|
||||
eval "$(zoxide init zsh --cmd cd)"
|
||||
|
||||
echo $kat
|
||||
# bun completions
|
||||
[ -s "/home/brk/.bun/_bun" ] && source "/home/brk/.bun/_bun"
|
||||
|
||||
# bun
|
||||
export BUN_INSTALL="$HOME/.bun"
|
||||
export PATH="$BUN_INSTALL/bin:$PATH"
|
||||
|
||||
if uwsm check may-start && uwsm select; then
|
||||
exec uwsm start default
|
||||
fi
|
||||
|
|
69
bin/1337x
Executable file
69
bin/1337x
Executable file
|
@ -0,0 +1,69 @@
|
|||
#!/usr/bin/bash
|
||||
|
||||
# 1337x.to, if this domain is blocked for you try to use 1377x.to or 1337xx.to.
|
||||
|
||||
clear
|
||||
mkdir -p $HOME/.cache/1337x
|
||||
|
||||
query=$*
|
||||
|
||||
baseurl="https://1337x.to"
|
||||
cachedir="$HOME/.cache/1337x"
|
||||
query="$(sed 's/ /+/g' <<<$query)"
|
||||
|
||||
# This is where default database can be chaned ie. Television, Movies, Music etc.
|
||||
# See https://1337x.to/ for a list of query strings.
|
||||
# curl -s https://www.1377x.to/category-search/$query/TV/1/ > $cachedir/tmp.html
|
||||
# curl -s https://www.1377x.to/category-search/$query/Music/1/ > $cachedir/tmp.html
|
||||
curl -s https://1337x.to/category-search/$query/Movies/1/ > $cachedir/tmp.html
|
||||
|
||||
# Get Titles
|
||||
grep -o '<a href="/torrent/.*</a>' $cachedir/tmp.html |
|
||||
sed 's/<[^>]*>//g' > $cachedir/titles.bw
|
||||
|
||||
result_count=$(wc -l $cachedir/titles.bw | awk '{print $1}')
|
||||
if [ "$result_count" -lt 1 ]; then
|
||||
notify-send "No Result found. Please try diffrent query."
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Seeders and Leechers
|
||||
grep -o '<td class="coll-2 seeds.*</td>\|<td class="coll-3 leeches.*</td>' $cachedir/tmp.html |
|
||||
sed 's/<[^>]*>//g' | sed 'N;s/\n/ /' > $cachedir/seedleech.bw
|
||||
|
||||
# Size
|
||||
grep -o '<td class="coll-4 size.*</td>' $cachedir/tmp.html |
|
||||
sed 's/<span class="seeds">.*<\/span>//g' |
|
||||
sed -e 's/<[^>]*>//g' > $cachedir/size.bw
|
||||
|
||||
# Links
|
||||
grep -E '/torrent/' $cachedir/tmp.html |
|
||||
sed -E 's#.*(/torrent/.*)/">.*/#\1#' |
|
||||
sed 's/td>//g' > $cachedir/links.bw
|
||||
|
||||
# Clearning up some data to display.
|
||||
sed 's/\./ /g; s/\-/ /g' $cachedir/titles.bw |
|
||||
sed 's/[^A-Za-z0-9 ]//g' | tr -s " " > $cachedir/tmp && mv $cachedir/tmp $cachedir/titles.bw
|
||||
|
||||
awk '{print NR " - ["$0"]"}' $cachedir/size.bw > $cachedir/tmp && mv $cachedir/tmp $cachedir/size.bw
|
||||
awk '{print "[S:"$1 ", L:"$2"]" }' $cachedir/seedleech.bw > $cachedir/tmp && mv $cachedir/tmp $cachedir/seedleech.bw
|
||||
|
||||
# Getting the line number.
|
||||
LINE=$(paste -d\ $cachedir/size.bw $cachedir/seedleech.bw $cachedir/titles.bw |
|
||||
fzf -i |
|
||||
cut -d\- -f1 |
|
||||
awk '{$1=$1; print}')
|
||||
|
||||
url=$(head -n $LINE $cachedir/links.bw 2> /dev/null | tail -n +$LINE 2> /dev/null)
|
||||
fullURL="${baseurl}${url}/"
|
||||
|
||||
# Requesting page for magnet link.
|
||||
curl -s $fullURL > $cachedir/tmp.html
|
||||
magnet=$(grep -Po "magnet:\?xt=urn:btih:[a-zA-Z0-9]*" $cachedir/tmp.html | head -n 1 2> /dev/null)
|
||||
|
||||
if [[ $magnet == '' ]]; then
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Default username:password passed by default.
|
||||
transmission-remote -n transmission:transmission --add "$magnet" && notify-send "Torrent added to queue."
|
BIN
bin/bin/ghostty
Executable file
BIN
bin/bin/ghostty
Executable file
Binary file not shown.
7
bin/fix-hyprland
Executable file
7
bin/fix-hyprland
Executable file
|
@ -0,0 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
sleep 1
|
||||
killall -9 -e xdg-desktop-portal-hyprland
|
||||
killall -9 xdg-desktop-portal
|
||||
/usr/lib/xdg-desktop-portal-hyprland &
|
||||
sleep 1
|
||||
/usr/lib/xdg-desktop-portal &
|
30
bin/msmtp-queue
Executable file
30
bin/msmtp-queue
Executable file
|
@ -0,0 +1,30 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
##--------------------------------------------------------------
|
||||
##
|
||||
## msmtp-queue : wrapper script for msmtpq
|
||||
## to expose the management functions
|
||||
## for the msmtp queue
|
||||
## Copyright (C) 2011 Chris Gianniotis
|
||||
##
|
||||
## This program is free software: you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published by
|
||||
## the Free Software Foundation, either version 3 of the License, or, at
|
||||
## your option, any later version.
|
||||
##
|
||||
##--------------------------------------------------------------
|
||||
|
||||
## msmtp-queue
|
||||
## is only a wrapper
|
||||
## it invokes the queue management functions of msmtpq
|
||||
## by calling it as msmtpq --q-mgmt
|
||||
##
|
||||
## all configuration and documentation is in the msmtpq script
|
||||
|
||||
## note that for 'special circumstances'
|
||||
## e.g. embedded systems, etc.
|
||||
## where the msmtpq script itself is not on the path
|
||||
## change the below line to be
|
||||
## exec /path/to/msmtpq --q-mgmt
|
||||
|
||||
exec msmtpq --q-mgmt "$1"
|
486
bin/msmtpq
Executable file
486
bin/msmtpq
Executable file
|
@ -0,0 +1,486 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
##--------------------------------------------------------------
|
||||
##
|
||||
## msmtpq : queue funtions to both use & manage the msmtp queue,
|
||||
## as it was defined by Martin Lambers
|
||||
## Copyright (C) 2008, 2009, 2010, 2011 Chris Gianniotis
|
||||
##
|
||||
## This program is free software: you can redistribute it and/or modify
|
||||
## it under the terms of the GNU General Public License as published by
|
||||
## the Free Software Foundation, either version 3 of the License, or, at
|
||||
## your option, any later version.
|
||||
##
|
||||
##--------------------------------------------------------------
|
||||
|
||||
## msmtpq is meant to be used by an email client - in 'sendmail' mode
|
||||
## for this purpose, it is invoked directly as 'msmtpq'
|
||||
## it is also meant to be used to maintain the msmtp queue
|
||||
## evoked by the wrapper script 'msmtp-queue'
|
||||
## (which calls this script as msmtpq --q-mgmt)
|
||||
|
||||
## there is a queue log file, distinct from the msmtp log,
|
||||
## for all events & operations on the msmtp queue
|
||||
## that is defined below
|
||||
|
||||
## (mutt users, using msmtpq in 'sendmail' mode,
|
||||
## should make at least the following two settings in their .muttrc
|
||||
## set sendmail = /path/to/msmtpq
|
||||
## set sendmail_wait = -1
|
||||
##
|
||||
## please see the msmtp man page and docs for further mutt settings
|
||||
## and optimisations
|
||||
## )
|
||||
|
||||
## msmtpq now uses the following environment variables :
|
||||
## EMAIL_CONN_NOTEST if set will suppress any testing for a connection
|
||||
## EMAIL_CONN_TEST if unset or =p will use a ping test (debian.org) for a connection
|
||||
## if =P will use a fast ping test (8.8.8.8) for a connection
|
||||
## if =n will use netcat (nc) to test for a connection
|
||||
## if =s will use bash sockets to test for a connection
|
||||
## EMAIL_QUEUE_QUIET if set will cause suppression of messages and 'chatter'
|
||||
|
||||
## two essential patches by Philipp Hartwig
|
||||
## 19 Oct 2011 & 27 Oct 2011
|
||||
|
||||
##--------------------------------------------------------------
|
||||
## the msmtp queue contains unique filenames of the following form :
|
||||
## two files for each mail in the queue
|
||||
##
|
||||
## creates new unique filenames of the form :
|
||||
## MLF: ccyy-mm-dd-hh.mm.ss[-x].mail -- mail file
|
||||
## MSF: ccyy-mm-dd-hh.mm.ss[-x].msmtp -- msmtp command line file
|
||||
## where x is a consecutive number only appended for uniqueness
|
||||
## if more than one mail per second is sent
|
||||
##--------------------------------------------------------------
|
||||
|
||||
|
||||
dsp() { local L ; for L ; do [ -n "$L" ] && echo " $L" || echo ; done ; }
|
||||
err() { dsp '' "$@" '' ; exit 1 ; }
|
||||
|
||||
|
||||
## ======================================================================================
|
||||
## !!! please define or confirm the following three vars !!!
|
||||
## !!! before using the msmtpq or msmtp-queue scripts !!!
|
||||
## ======================================================================================
|
||||
##
|
||||
## only if necessary (in unusual circumstances - e.g. embedded systems),
|
||||
## enter the location of the msmtp executable (no quotes !!)
|
||||
## e.g. ( MSMTP=/path/to/msmtp )
|
||||
MSMTP=msmtp
|
||||
#[ -x "$MSMTP" ] || \
|
||||
# log -e 1 "msmtpq : can't find the msmtp executable [ $MSMTP ]" # if not found - complain ; quit
|
||||
##
|
||||
## set the queue var to the location of the msmtp queue directory
|
||||
## if the queue dir doesn't yet exist, better to create it (0700)
|
||||
## before using this routine
|
||||
## e.g. ( mkdir msmtp.queue )
|
||||
## ( chmod 0700 msmtp.queue )
|
||||
##
|
||||
## the queue dir - modify this to reflect where you'd like it to be (no quotes !!)
|
||||
Q=~/.msmtp.queue
|
||||
[ -d "$Q" ] || \
|
||||
err '' "msmtpq : can't find msmtp queue directory [ $Q ]" '' # if not present - complain ; quit
|
||||
##
|
||||
## set the queue log file var to the location of the msmtp queue log file
|
||||
## where it is or where you'd like it to be
|
||||
## ( note that the LOG setting could be the same as the )
|
||||
## ( 'logfile' setting in .msmtprc - but there may be )
|
||||
## ( some advantage in keeping the two logs separate )
|
||||
## if you don't want the log at all unset (comment out) this var
|
||||
## LOG=~/log/msmtp.queue.log --> #LOG=~/log/msmtp.queue.log
|
||||
## (doing so would be inadvisable under most conditions, however)
|
||||
##
|
||||
## the queue log file - modify (or comment out) to taste (but no quotes !!)
|
||||
LOG=~/log/msmtp.queue.log
|
||||
## ======================================================================================
|
||||
|
||||
umask 077 # set secure permissions on created directories and files
|
||||
|
||||
declare -i CNT # a count of mail(s) currently in the queue
|
||||
declare -a Q_LST # queue list array ; used selecting a mail (to send or remove)
|
||||
|
||||
## do ; test this !
|
||||
#for sig in INT TERM EXIT; do
|
||||
# trap "rm -f \"\$TMPFILE\"; [[ $sig == EXIT ]] || kill -$sig $$" $sig
|
||||
#done
|
||||
trap on_exit INT TERM EXIT # run 'on_exit' on exit
|
||||
on_exit() {
|
||||
[ -n "$LKD" ] && lock_queue -u 2>/dev/null # unlock the queue on exit if the lock was set here
|
||||
}
|
||||
|
||||
#
|
||||
## ----------------------------------- common functions
|
||||
#
|
||||
|
||||
## make an entry to the queue log file, possibly an error
|
||||
## (log queue changes only ; not interactive chatter)
|
||||
## usage : log [ -e errcode ] msg [ msg ... ]
|
||||
## opts : -e <exit code> an error ; log msg & terminate w/prejudice
|
||||
## display msg to user, as well
|
||||
log() {
|
||||
local ARG RC PFX="$('date' +'%Y %d %b %H:%M:%S')"
|
||||
# time stamp prefix - "2008 13 Mar 03:59:45 "
|
||||
if [ "$1" = '-e' ] ; then # there's an error exit code
|
||||
RC="$2" # take it
|
||||
shift 2 # shift opt & its arg off
|
||||
fi
|
||||
|
||||
[ -z "$EMAIL_QUEUE_QUIET" ] && dsp "$@" # display msg to user, as well as logging it
|
||||
|
||||
if [ -n "$LOG" ] ; then # log is defined and in use
|
||||
for ARG ; do # each msg line out
|
||||
[ -n "$ARG" ] && \
|
||||
echo "$PFX : $ARG" >> "$LOG" # line has content ; send it to log
|
||||
done
|
||||
fi
|
||||
|
||||
if [ -n "$RC" ] ; then # an error ; leave w/error return
|
||||
[ -n "$LKD" ] && lock_queue -u # unlock here (if locked)
|
||||
[ -n "$LOG" ] && \
|
||||
echo " exit code = $RC" >> "$LOG" # logging ok ; send exit code to log
|
||||
exit $RC # exit w/return code
|
||||
fi
|
||||
}
|
||||
|
||||
## write/remove queue lockfile for a queue op
|
||||
lock_queue() { # <-- '-u' to remove lockfile
|
||||
local LOK="${Q}/.lock" # lock file name
|
||||
local -i MAX=240 SEC=0 # max seconds to gain a lock ; seconds waiting
|
||||
|
||||
if [ -z "$1" ] ; then # lock queue
|
||||
## Philipp Hartwig patch #2
|
||||
'mkdir' "$LOK" 2>/dev/null && LKD='t'
|
||||
while [ -z "$LKD" ] && (( SEC < MAX )) ; do # lock file present
|
||||
sleep 1 # wait a second
|
||||
(( ++SEC )) # accumulate seconds
|
||||
'mkdir' "$LOK" 2>/dev/null && LKD='t' # make lockdir ; lock queue ; set flag
|
||||
done # try again while locked for MAX secs
|
||||
[ -z "$LKD" ] && \
|
||||
err '' "cannot use queue $Q : waited $MAX seconds for"\
|
||||
" lockdir [ $LOK ] to vanish ; giving up"\
|
||||
'if you are certain that no other instance of this script'\
|
||||
" is running, then 'rmdir' the lock dir manually" '' # lock file still there, give up
|
||||
|
||||
elif [ "$1" = '-u' ] ; then # unlock queue
|
||||
'rmdir' "$LOK" # remove the lock
|
||||
unset LKD # unset flag
|
||||
fi
|
||||
}
|
||||
|
||||
## test whether system is connected
|
||||
## returns t/f (0/1)
|
||||
connect_test() {
|
||||
if [ -z "$EMAIL_CONN_TEST" ] || \
|
||||
[ "$EMAIL_CONN_TEST" = 'p' ] ; then # use ping test (default)
|
||||
# verify net connection - ping ip address of debian.org
|
||||
# would ping -qnc2 -w4 be better ?
|
||||
# would ping -qnc1 -w10 or -w20 be better ?
|
||||
ping -qnc1 -w4 debian.org >/dev/null 2>&1 || return 1
|
||||
elif [ "$EMAIL_CONN_TEST" = 'P' ] ; then # use quicker ping test
|
||||
# I personally think that including a DNS lookup
|
||||
# is a better connection test but some
|
||||
# have found the above test too slow
|
||||
ping -qnc1 -w4 8.8.8.8 >/dev/null 2>&1 || return 1
|
||||
elif [ "$EMAIL_CONN_TEST" = 'n' ] ; then # use netcat (nc) test
|
||||
# must, of course, have netcat (nc) installed
|
||||
which nc >/dev/null 2>&1 || \
|
||||
log -e 1 "msmtpq : can't find netcat executable [ nc ]" # if not found - complain ; quit
|
||||
'nc' -vz www.debian.org 80 || return 1
|
||||
elif [ "$EMAIL_CONN_TEST" = 's' ] ; then # use sh sockets test
|
||||
# note that this does not work on debian systems
|
||||
# where bash opened sockets are suppressed for security reasons
|
||||
# this should be ok for single user systems (including embedded systems)
|
||||
# test whether this is supported on your system before using
|
||||
exec 3<>/dev/udp/debian.org/80 || return 1 # open socket on site ; use dns
|
||||
exec 3<&- ; exec 3>&- # close socket
|
||||
fi
|
||||
return 0
|
||||
}
|
||||
|
||||
#
|
||||
## ----------------------------------- functions for queue management
|
||||
## ----------------------------------- queue maintenance mode - (msmtp-queue)
|
||||
#
|
||||
|
||||
## show queue maintenance functions
|
||||
usage() { # <-- error msg
|
||||
dsp ''\
|
||||
'usage : msmtp-queue functions' ''\
|
||||
' msmtp-queue < op >'\
|
||||
' ops : -r run (flush) mail queue - all mail in queue'\
|
||||
' -R send selected individual mail(s) in queue'\
|
||||
' -d display (list) queue contents (<-- default)'\
|
||||
' -p purge individual mail(s) from queue'\
|
||||
' -a purge all mail in queue'\
|
||||
' -h this helpful blurt' ''\
|
||||
' ( one op only ; any others ignored )' ''
|
||||
[ -z "$1" ] && exit 0 || { dsp "$@" '' ; exit 1 ; }
|
||||
}
|
||||
|
||||
## get user [y/n] acknowledgement
|
||||
ok() {
|
||||
local R YN='Y/n' # default to yes
|
||||
|
||||
[ "$1" = '-n' ] && \
|
||||
{ YN='y/N' ; shift ; } # default to no ; change prompt ; shift off spec
|
||||
|
||||
dsp "$@"
|
||||
while true ; do
|
||||
echo -n " ok [${YN}] ..: "
|
||||
read R
|
||||
case $R in
|
||||
y|Y) return 0 ;;
|
||||
n|N) return 1 ;;
|
||||
'') [ "$YN" = 'Y/n' ] && return 0 || return 1 ;;
|
||||
*) echo 'yYnN<cr> only please' ;;
|
||||
esac
|
||||
done
|
||||
}
|
||||
|
||||
## send a queued mail out via msmtp
|
||||
send_queued_mail() { # <-- mail id
|
||||
local FQP="${Q}/${1}" # fully qualified path name
|
||||
local -i RC=0 # for msmtp exit code
|
||||
|
||||
if [ -f "${FQP}.msmtp" ] ; then # corresponding .msmtp file found
|
||||
[ -z "$EMAIL_CONN_NOTEST" ] && { # connection test
|
||||
connect_test || \
|
||||
log "mail [ $2 ] [ $1 ] from queue ; couldn't be sent - host not connected"
|
||||
}
|
||||
|
||||
if $MSMTP $(< "${FQP}.msmtp") < "${FQP}.mail" ; then # this mail goes out the door
|
||||
log "mail [ $2 ] [ $1 ] from queue ; send was successful ; purged from queue" # good news to user
|
||||
'rm' -f ${FQP}.* # nuke both queue mail files
|
||||
ALT='t' # set queue changed flag
|
||||
else # send was unsuccessful
|
||||
RC=$? # take msmtp exit code
|
||||
log "mail [ $2 ] [ $1 ] from queue ; send failed ; msmtp rc = $RC" # bad news ...
|
||||
fi
|
||||
return $RC # func returns exit code
|
||||
else # corresponding MSF file not found
|
||||
log "preparing to send .mail file [ $1 ] [ ${FQP}.mail ] but"\
|
||||
" corresponding .msmtp file [ ${FQP}.msmtp ] was not found in queue"\
|
||||
' skipping this mail ; this is worth looking into' # give user the bad news
|
||||
fi # (but allow continuation)
|
||||
}
|
||||
|
||||
## run (flush) queue
|
||||
run_queue() { # <- 'sm' mode # run queue
|
||||
local M LST="$('ls' $Q/*.mail 2>/dev/null)" # list of mails in queue
|
||||
local -i NDX=0
|
||||
|
||||
if [ -n "$LST" ] ; then # something in queue
|
||||
for M in $LST ; do # process all mails
|
||||
((NDX++))
|
||||
send_queued_mail "$(basename $M .mail)" "$NDX" # send mail - pass {id} only
|
||||
done
|
||||
else # queue is empty
|
||||
[ -z "$1" ] && \
|
||||
dsp '' 'mail queue is empty (nothing to send)' ''
|
||||
fi # inform user (if not running in sendmail mode)
|
||||
}
|
||||
|
||||
## display queue contents
|
||||
display_queue() { # <-- { 'purge' | 'send' } (op label) ; { 'rec' } (record array of mail ids)
|
||||
local M ID LST="$('ls' ${Q}/*.mail 2>/dev/null)" # list of mail ids in queue
|
||||
|
||||
CNT=0
|
||||
if [ -n "$LST" ] ; then # list has contents (any mails in queue)
|
||||
for M in $LST ; do # cycle through each
|
||||
ID="$(basename $M .mail)" # take mail id from filename
|
||||
((CNT++))
|
||||
dsp '' "mail num=[ $CNT ] id=[ $ID ]" # show mail id ## patch in
|
||||
'egrep' -s --colour -h '(^From:|^To:|^Subject:)' "$M" # show mail info
|
||||
[ -n "$2" ] && Q_LST[$CNT]="$ID" # bang mail id into array (note 1-based array indexing)
|
||||
done
|
||||
echo
|
||||
else # no mails ; no contents
|
||||
[ -z "$1" ] && \
|
||||
dsp '' 'no mail in queue' '' || \
|
||||
dsp '' "mail queue is empty (nothing to $1)" '' # inform user
|
||||
exit 0
|
||||
fi
|
||||
}
|
||||
|
||||
## delete all mail in queue, after confirmation
|
||||
purge_queue() {
|
||||
display_queue 'purge' # show queue contents
|
||||
if ok -n 'remove (purge) all mail from the queue' ; then
|
||||
lock_queue # lock here
|
||||
'rm' -f "$Q"/*.*
|
||||
log 'msmtp queue purged (all mail)'
|
||||
lock_queue -u # unlock here
|
||||
else
|
||||
dsp '' 'nothing done ; queue is untouched' ''
|
||||
fi
|
||||
}
|
||||
|
||||
## select a single mail from queue ; delete it or send it
|
||||
## select by mail index (position in queue) or mail id
|
||||
select_mail() { # <-- < 'purge' | 'send' >
|
||||
local OK ID # mail id
|
||||
local -i I NDX # mail index (position in queue)
|
||||
|
||||
while true ; do # purge an individual mail from queue
|
||||
display_queue "$1" 'rec' # show queue contents ; make mail ids array
|
||||
|
||||
## allow selection also by mail index
|
||||
if [ $CNT -eq 1 ] ; then # only one mail in queue ; take its id
|
||||
NDX=1
|
||||
ID="${Q_LST[1]}"
|
||||
else # more than one mail ; select its id
|
||||
while true ; do # get mail id
|
||||
OK='t' # optimistic to a fault
|
||||
dsp "enter mail number or id to $1" # <-- num or file name (only, no suff)
|
||||
echo -n ' ( <cr> alone to exit ) ..: '
|
||||
read ID
|
||||
[ -n "$ID" ] || return # entry made - or say good bye
|
||||
|
||||
if [ "${ID:4:1}" != '-' ] ; then # mail id *not* entered ; test index num
|
||||
for (( I=0 ; I<${#ID} ; I++ )) ; do # test index number
|
||||
if [[ "${ID:${I}:1}" < '0' || \
|
||||
"${ID:${I}:1}" > '9' ]] ; then
|
||||
dsp '' "[ $ID ] is neither a valid mail id"\
|
||||
'nor a valid mail number' ''
|
||||
unset OK
|
||||
fi
|
||||
done
|
||||
[ -z "$OK" ] && continue # format not ok (not all nums)
|
||||
|
||||
NDX=$ID
|
||||
if [ $NDX -lt 1 ] || [ $NDX -gt $CNT ] ; then # test number range (1 - $CNT)
|
||||
dsp '' "[ $NDX ] is out of range as a mail number"\
|
||||
"validity is from 1 to $CNT"
|
||||
continue # try again
|
||||
fi
|
||||
|
||||
ID="${Q_LST[$NDX]}" # format & range were ok ; use it
|
||||
break # valid mail selection
|
||||
else # mail id entered
|
||||
for (( NDX=1 ; NDX<=${#Q_LST[*]} ; NDX++ )) ; do # find entered id in queue list
|
||||
[ "$ID" = "${Q_LST[$NDX]}" ] && break
|
||||
done
|
||||
[ $NDX -le ${#Q_LST[*]} ] && \
|
||||
break || \
|
||||
dsp '' "mail [ $ID ] not found ; invalid id" # mail selection valid (found) or
|
||||
fi # fell through (not found) complain
|
||||
done # and ask again
|
||||
fi
|
||||
|
||||
if ok '' "$1 :"\
|
||||
" mail num=[ $NDX ]"\
|
||||
" id=[ $ID ]" '' ; then # confirm mail op
|
||||
if [ "$1" = 'purge' ] ; then # purging
|
||||
lock_queue # lock here
|
||||
'rm' -f "$Q"/"$ID".* # msmtp - nukes single mail (both files) in queue
|
||||
log "mail [ $ID ] purged from queue" # log op
|
||||
lock_queue -u # unlock here
|
||||
ALT='t' # mark that a queue alteration has taken place
|
||||
else # sending
|
||||
lock_queue # lock here
|
||||
send_queued_mail "$ID" "$NDX" # send out the mail
|
||||
lock_queue -u # unlock here
|
||||
fi
|
||||
else # user opts out
|
||||
dsp '' 'nothing done to this queued email' # soothe user
|
||||
[ $CNT -eq 1 ] && break # single mail ; user opted out
|
||||
fi
|
||||
dsp '' "--------------------------------------------------"
|
||||
done
|
||||
|
||||
if [ -n "$ALT" ] ; then # queue was changed
|
||||
dsp '' 'done' ''
|
||||
else # queue is untouched
|
||||
dsp '' 'nothing done ; queue is untouched' ''
|
||||
fi
|
||||
}
|
||||
|
||||
#
|
||||
## ----------------------------------- functions for directly sending mail
|
||||
## ----------------------------------- 'sendmail' mode - (msmtpq)
|
||||
#
|
||||
|
||||
## ('sendmail' mode only)
|
||||
## make base filename id for queue
|
||||
make_id() {
|
||||
local -i INC # increment counter for (possible) base fqp name collision
|
||||
|
||||
ID="$(date +%Y-%m-%d-%H.%M.%S)" # make filename id for queue (global
|
||||
FQP="${Q}/$ID" # make fully qualified pathname vars)
|
||||
## Philipp Hartwig patch #1
|
||||
if [ -f "${FQP}.mail" -o -f "${FQP}.msmtp" ] ; then # ensure fqp name is unique
|
||||
INC=1 # initial increment
|
||||
while [ -f "${FQP}-${INC}.mail" -o -f "${FQP}-${INC}.msmtp" ] ; do # fqp name w/incr exists
|
||||
(( ++INC )) # bump increment
|
||||
done
|
||||
ID="${ID}-${INC}" # unique ; set id
|
||||
FQP="${FQP}-${INC}" # unique ; set fqp name
|
||||
fi
|
||||
}
|
||||
|
||||
## ('sendmail' mode only)
|
||||
## enqueue a mail
|
||||
enqueue_mail() { # <-- all mail args ; mail text via TMP
|
||||
if echo "$@" > "${FQP}.msmtp" ; then # write msmtp command line to queue .msmtp file
|
||||
log "enqueued mail as : [ $ID ] ( $* ) : successful" # (queue .mail file is already there)
|
||||
else # write failed ; bomb
|
||||
log -e "$?" "queueing - writing msmtp cmd line { $* }"\
|
||||
" to [ ${ID}.msmtp ] : failed"
|
||||
fi
|
||||
}
|
||||
|
||||
## ('sendmail' mode only)
|
||||
## send a mail (if possible, otherwise enqueue it)
|
||||
## if send is successful, msmtp will also log it (if enabled in ~/.msmtprc)
|
||||
send_mail() { # <-- all mail args ; mail text via TMP
|
||||
[ -z "$EMAIL_CONN_NOTEST" ] && { # connection test
|
||||
connect_test || {
|
||||
log "mail for [ $* ] : couldn't be sent - host not connected"
|
||||
enqueue_mail "$@" # enqueue the mail
|
||||
}
|
||||
}
|
||||
|
||||
if $MSMTP "$@" < "${FQP}.mail" > /dev/null ; then # send mail using queue .mail fil
|
||||
log "mail for [ $* ] : send was successful" # log it
|
||||
'rm' -f ${FQP}.* # remove all queue mail files .mail & .msmtp file
|
||||
run_queue 'sm' # run/flush any other mails in queue
|
||||
else # send failed - the mail stays in the queue
|
||||
log "mail for [ $* ] : send was unsuccessful ; msmtp exit code was $?"\
|
||||
"enqueued mail as : [ $ID ] ( $* )" # (queue .mail file is already there)
|
||||
fi
|
||||
}
|
||||
|
||||
#
|
||||
## -- entry point
|
||||
#
|
||||
|
||||
if [ ! "$1" = '--q-mgmt' ] ; then # msmtpq - sendmail mode
|
||||
lock_queue # lock here
|
||||
make_id # make base queue filename id for this mail
|
||||
# write mail body text to queue .mail file
|
||||
cat > "${FQP}.mail" || \
|
||||
log -e "$?" "creating mail body file [ ${FQP}.mail ] : failed" # test for error
|
||||
# write msmtp command line to queue .msmtp file
|
||||
echo "$@" > "${FQP}.msmtp" || \
|
||||
log -e "$?" "creating msmtp cmd line file { $* }"\
|
||||
" to [ ${ID}.msmtp ] : failed" # test for error
|
||||
send_mail "$@" # send the mail if possible, queue it if not
|
||||
lock_queue -u # unlock here
|
||||
else # msmtp-queue - queue management mode
|
||||
shift # trim off first (--q-mgmt) arg
|
||||
OP=${1:1} # trim off first char of OP arg
|
||||
case "$OP" in # sort ops ; run according to spec
|
||||
r) lock_queue
|
||||
run_queue
|
||||
lock_queue -u ;; # run (flush) the queue
|
||||
R) select_mail send ;; # send individual mail(s) in queue
|
||||
d|'') display_queue ;; # display (list) all mail in queue (default)
|
||||
p) select_mail purge ;; # purge individual mail(s) from queue
|
||||
a) purge_queue ;; # purge all mail in queue
|
||||
h) usage ;; # show help
|
||||
*) usage "[ -$OP ] is an unknown msmtp-queue option" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
exit 0
|
8
bin/secret.sh
Executable file
8
bin/secret.sh
Executable file
|
@ -0,0 +1,8 @@
|
|||
#!/bin/sh
|
||||
|
||||
gopass show -o "$1" "$2"
|
||||
# wait until the password is available
|
||||
while [ $? != 0 ]; do
|
||||
gopass show -o "$1" "$2"
|
||||
done
|
||||
|
16
bin/share/applications/com.mitchellh.ghostty.desktop
Normal file
16
bin/share/applications/com.mitchellh.ghostty.desktop
Normal file
|
@ -0,0 +1,16 @@
|
|||
[Desktop Entry]
|
||||
Name=Ghostty
|
||||
Type=Application
|
||||
Comment=A terminal emulator
|
||||
Exec=ghostty
|
||||
Icon=com.mitchellh.ghostty
|
||||
Categories=System;TerminalEmulator;
|
||||
Keywords=terminal;tty;pty;
|
||||
StartupNotify=true
|
||||
Terminal=false
|
||||
Actions=new-window;
|
||||
X-GNOME-UsesNotifications=true
|
||||
|
||||
[Desktop Action new-window]
|
||||
Name=New Window
|
||||
Exec=ghostty
|
440
bin/share/bash-completion/completions/ghostty.bash
Normal file
440
bin/share/bash-completion/completions/ghostty.bash
Normal file
|
@ -0,0 +1,440 @@
|
|||
# -o nospace requires we add back a space when a completion is finished
|
||||
# and not part of a --key= completion
|
||||
addSpaces() {
|
||||
for idx in "${!COMPREPLY[@]}"; do
|
||||
[ -n "${COMPREPLY[idx]}" ] && COMPREPLY[idx]="${COMPREPLY[idx]} ";
|
||||
done
|
||||
}
|
||||
|
||||
_fonts() {
|
||||
local IFS=$'\n'
|
||||
mapfile -t COMPREPLY < <( compgen -P '"' -S '"' -W "$($ghostty +list-fonts | grep '^[A-Z]' )" -- "$cur")
|
||||
}
|
||||
|
||||
_themes() {
|
||||
local IFS=$'\n'
|
||||
mapfile -t COMPREPLY < <( compgen -P '"' -S '"' -W "$($ghostty +list-themes | sed -E 's/^(.*) \(.*$/\1/')" -- "$cur")
|
||||
}
|
||||
|
||||
_files() {
|
||||
mapfile -t COMPREPLY < <( compgen -o filenames -f -- "$cur" )
|
||||
for i in "${!COMPREPLY[@]}"; do
|
||||
if [[ -d "${COMPREPLY[i]}" ]]; then
|
||||
COMPREPLY[i]="${COMPREPLY[i]}/";
|
||||
fi
|
||||
if [[ -f "${COMPREPLY[i]}" ]]; then
|
||||
COMPREPLY[i]="${COMPREPLY[i]} ";
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
_dirs() {
|
||||
mapfile -t COMPREPLY < <( compgen -o dirnames -d -- "$cur" )
|
||||
for i in "${!COMPREPLY[@]}"; do
|
||||
if [[ -d "${COMPREPLY[i]}" ]]; then
|
||||
COMPREPLY[i]="${COMPREPLY[i]}/";
|
||||
fi
|
||||
done
|
||||
if [[ "${#COMPREPLY[@]}" == 0 && -d "$cur" ]]; then
|
||||
COMPREPLY=( "$cur " )
|
||||
fi
|
||||
}
|
||||
|
||||
config="--help"
|
||||
config+=" --version"
|
||||
config+=" --font-family="
|
||||
config+=" --font-family-bold="
|
||||
config+=" --font-family-italic="
|
||||
config+=" --font-family-bold-italic="
|
||||
config+=" --font-style="
|
||||
config+=" --font-style-bold="
|
||||
config+=" --font-style-italic="
|
||||
config+=" --font-style-bold-italic="
|
||||
config+=" --font-synthetic-style="
|
||||
config+=" --font-feature="
|
||||
config+=" --font-size="
|
||||
config+=" --font-variation="
|
||||
config+=" --font-variation-bold="
|
||||
config+=" --font-variation-italic="
|
||||
config+=" --font-variation-bold-italic="
|
||||
config+=" --font-codepoint-map="
|
||||
config+=" '--font-thicken '"
|
||||
config+=" --adjust-cell-width="
|
||||
config+=" --adjust-cell-height="
|
||||
config+=" --adjust-font-baseline="
|
||||
config+=" --adjust-underline-position="
|
||||
config+=" --adjust-underline-thickness="
|
||||
config+=" --adjust-strikethrough-position="
|
||||
config+=" --adjust-strikethrough-thickness="
|
||||
config+=" --adjust-overline-position="
|
||||
config+=" --adjust-overline-thickness="
|
||||
config+=" --adjust-cursor-thickness="
|
||||
config+=" --adjust-box-thickness="
|
||||
config+=" --grapheme-width-method="
|
||||
config+=" --freetype-load-flags="
|
||||
config+=" --theme="
|
||||
config+=" --background="
|
||||
config+=" --foreground="
|
||||
config+=" --selection-foreground="
|
||||
config+=" --selection-background="
|
||||
config+=" '--selection-invert-fg-bg '"
|
||||
config+=" --minimum-contrast="
|
||||
config+=" --palette="
|
||||
config+=" --cursor-color="
|
||||
config+=" '--cursor-invert-fg-bg '"
|
||||
config+=" --cursor-opacity="
|
||||
config+=" --cursor-style="
|
||||
config+=" '--cursor-style-blink '"
|
||||
config+=" --cursor-text="
|
||||
config+=" '--cursor-click-to-move '"
|
||||
config+=" '--mouse-hide-while-typing '"
|
||||
config+=" --mouse-shift-capture="
|
||||
config+=" --mouse-scroll-multiplier="
|
||||
config+=" --background-opacity="
|
||||
config+=" --background-blur-radius="
|
||||
config+=" --unfocused-split-opacity="
|
||||
config+=" --unfocused-split-fill="
|
||||
config+=" --command="
|
||||
config+=" --initial-command="
|
||||
config+=" '--wait-after-command '"
|
||||
config+=" --abnormal-command-exit-runtime="
|
||||
config+=" --scrollback-limit="
|
||||
config+=" --link="
|
||||
config+=" '--link-url '"
|
||||
config+=" '--fullscreen '"
|
||||
config+=" --title="
|
||||
config+=" --class="
|
||||
config+=" --x11-instance-name="
|
||||
config+=" --working-directory="
|
||||
config+=" --keybind="
|
||||
config+=" --window-padding-x="
|
||||
config+=" --window-padding-y="
|
||||
config+=" '--window-padding-balance '"
|
||||
config+=" --window-padding-color="
|
||||
config+=" '--window-vsync '"
|
||||
config+=" '--window-inherit-working-directory '"
|
||||
config+=" '--window-inherit-font-size '"
|
||||
config+=" '--window-decoration '"
|
||||
config+=" --window-title-font-family="
|
||||
config+=" --window-theme="
|
||||
config+=" --window-colorspace="
|
||||
config+=" --window-height="
|
||||
config+=" --window-width="
|
||||
config+=" --window-save-state="
|
||||
config+=" '--window-step-resize '"
|
||||
config+=" --window-new-tab-position="
|
||||
config+=" --resize-overlay="
|
||||
config+=" --resize-overlay-position="
|
||||
config+=" --resize-overlay-duration="
|
||||
config+=" '--focus-follows-mouse '"
|
||||
config+=" --clipboard-read="
|
||||
config+=" --clipboard-write="
|
||||
config+=" '--clipboard-trim-trailing-spaces '"
|
||||
config+=" '--clipboard-paste-protection '"
|
||||
config+=" '--clipboard-paste-bracketed-safe '"
|
||||
config+=" --image-storage-limit="
|
||||
config+=" --copy-on-select="
|
||||
config+=" --click-repeat-interval="
|
||||
config+=" --config-file="
|
||||
config+=" '--config-default-files '"
|
||||
config+=" '--confirm-close-surface '"
|
||||
config+=" '--quit-after-last-window-closed '"
|
||||
config+=" --quit-after-last-window-closed-delay="
|
||||
config+=" '--initial-window '"
|
||||
config+=" --quick-terminal-position="
|
||||
config+=" --quick-terminal-screen="
|
||||
config+=" --quick-terminal-animation-duration="
|
||||
config+=" --shell-integration="
|
||||
config+=" --shell-integration-features="
|
||||
config+=" --osc-color-report-format="
|
||||
config+=" '--vt-kam-allowed '"
|
||||
config+=" --custom-shader="
|
||||
config+=" --custom-shader-animation="
|
||||
config+=" --macos-non-native-fullscreen="
|
||||
config+=" --macos-titlebar-style="
|
||||
config+=" --macos-titlebar-proxy-icon="
|
||||
config+=" --macos-option-as-alt="
|
||||
config+=" '--macos-window-shadow '"
|
||||
config+=" '--macos-auto-secure-input '"
|
||||
config+=" '--macos-secure-input-indication '"
|
||||
config+=" --linux-cgroup="
|
||||
config+=" --linux-cgroup-memory-limit="
|
||||
config+=" --linux-cgroup-processes-limit="
|
||||
config+=" '--linux-cgroup-hard-fail '"
|
||||
config+=" --gtk-single-instance="
|
||||
config+=" '--gtk-titlebar '"
|
||||
config+=" --gtk-tabs-location="
|
||||
config+=" --adw-toolbar-style="
|
||||
config+=" '--gtk-wide-tabs '"
|
||||
config+=" '--gtk-adwaita '"
|
||||
config+=" '--desktop-notifications '"
|
||||
config+=" '--bold-is-bright '"
|
||||
config+=" --term="
|
||||
config+=" --enquiry-response="
|
||||
config+=" --auto-update="
|
||||
config+=" --auto-update-channel="
|
||||
|
||||
_handleConfig() {
|
||||
case "$prev" in
|
||||
--font-family) _fonts ;;
|
||||
--font-family-bold) _fonts ;;
|
||||
--font-family-italic) _fonts ;;
|
||||
--font-family-bold-italic) _fonts ;;
|
||||
--font-style) return ;;
|
||||
--font-style-bold) return ;;
|
||||
--font-style-italic) return ;;
|
||||
--font-style-bold-italic) return ;;
|
||||
--font-synthetic-style) mapfile -t COMPREPLY < <( compgen -W "bold no-bold italic no-italic bold-italic no-bold-italic" -- "$cur" ); addSpaces ;;
|
||||
--font-feature) return ;;
|
||||
--font-size) return ;;
|
||||
--font-variation) return ;;
|
||||
--font-variation-bold) return ;;
|
||||
--font-variation-italic) return ;;
|
||||
--font-variation-bold-italic) return ;;
|
||||
--font-codepoint-map) return ;;
|
||||
--font-thicken) return ;;
|
||||
--adjust-cell-width) return ;;
|
||||
--adjust-cell-height) return ;;
|
||||
--adjust-font-baseline) return ;;
|
||||
--adjust-underline-position) return ;;
|
||||
--adjust-underline-thickness) return ;;
|
||||
--adjust-strikethrough-position) return ;;
|
||||
--adjust-strikethrough-thickness) return ;;
|
||||
--adjust-overline-position) return ;;
|
||||
--adjust-overline-thickness) return ;;
|
||||
--adjust-cursor-thickness) return ;;
|
||||
--adjust-box-thickness) return ;;
|
||||
--grapheme-width-method) mapfile -t COMPREPLY < <( compgen -W "legacy unicode" -- "$cur" ); addSpaces ;;
|
||||
--freetype-load-flags) mapfile -t COMPREPLY < <( compgen -W "hinting no-hinting force-autohint no-force-autohint monochrome no-monochrome autohint no-autohint" -- "$cur" ); addSpaces ;;
|
||||
--theme) _themes ;;
|
||||
--background) return ;;
|
||||
--foreground) return ;;
|
||||
--selection-foreground) return ;;
|
||||
--selection-background) return ;;
|
||||
--selection-invert-fg-bg) return ;;
|
||||
--minimum-contrast) return ;;
|
||||
--palette) return ;;
|
||||
--cursor-color) return ;;
|
||||
--cursor-invert-fg-bg) return ;;
|
||||
--cursor-opacity) return ;;
|
||||
--cursor-style) mapfile -t COMPREPLY < <( compgen -W "bar block underline block_hollow" -- "$cur" ); addSpaces ;;
|
||||
--cursor-style-blink) return ;;
|
||||
--cursor-text) return ;;
|
||||
--cursor-click-to-move) return ;;
|
||||
--mouse-hide-while-typing) return ;;
|
||||
--mouse-shift-capture) mapfile -t COMPREPLY < <( compgen -W "false true always never" -- "$cur" ); addSpaces ;;
|
||||
--mouse-scroll-multiplier) return ;;
|
||||
--background-opacity) return ;;
|
||||
--background-blur-radius) return ;;
|
||||
--unfocused-split-opacity) return ;;
|
||||
--unfocused-split-fill) return ;;
|
||||
--command) return ;;
|
||||
--initial-command) return ;;
|
||||
--wait-after-command) return ;;
|
||||
--abnormal-command-exit-runtime) return ;;
|
||||
--scrollback-limit) return ;;
|
||||
--link) return ;;
|
||||
--link-url) return ;;
|
||||
--fullscreen) return ;;
|
||||
--title) return ;;
|
||||
--class) return ;;
|
||||
--x11-instance-name) return ;;
|
||||
--working-directory) _dirs ;;
|
||||
--keybind) return ;;
|
||||
--window-padding-x) return ;;
|
||||
--window-padding-y) return ;;
|
||||
--window-padding-balance) return ;;
|
||||
--window-padding-color) mapfile -t COMPREPLY < <( compgen -W "background extend extend-always" -- "$cur" ); addSpaces ;;
|
||||
--window-vsync) return ;;
|
||||
--window-inherit-working-directory) return ;;
|
||||
--window-inherit-font-size) return ;;
|
||||
--window-decoration) return ;;
|
||||
--window-title-font-family) return ;;
|
||||
--window-theme) mapfile -t COMPREPLY < <( compgen -W "auto system light dark ghostty" -- "$cur" ); addSpaces ;;
|
||||
--window-colorspace) mapfile -t COMPREPLY < <( compgen -W "srgb display-p3" -- "$cur" ); addSpaces ;;
|
||||
--window-height) return ;;
|
||||
--window-width) return ;;
|
||||
--window-save-state) mapfile -t COMPREPLY < <( compgen -W "default never always" -- "$cur" ); addSpaces ;;
|
||||
--window-step-resize) return ;;
|
||||
--window-new-tab-position) mapfile -t COMPREPLY < <( compgen -W "current end" -- "$cur" ); addSpaces ;;
|
||||
--resize-overlay) mapfile -t COMPREPLY < <( compgen -W "always never after-first" -- "$cur" ); addSpaces ;;
|
||||
--resize-overlay-position) mapfile -t COMPREPLY < <( compgen -W "center top-left top-center top-right bottom-left bottom-center bottom-right" -- "$cur" ); addSpaces ;;
|
||||
--resize-overlay-duration) return ;;
|
||||
--focus-follows-mouse) return ;;
|
||||
--clipboard-read) mapfile -t COMPREPLY < <( compgen -W "allow deny ask" -- "$cur" ); addSpaces ;;
|
||||
--clipboard-write) mapfile -t COMPREPLY < <( compgen -W "allow deny ask" -- "$cur" ); addSpaces ;;
|
||||
--clipboard-trim-trailing-spaces) return ;;
|
||||
--clipboard-paste-protection) return ;;
|
||||
--clipboard-paste-bracketed-safe) return ;;
|
||||
--image-storage-limit) return ;;
|
||||
--copy-on-select) mapfile -t COMPREPLY < <( compgen -W "false true clipboard" -- "$cur" ); addSpaces ;;
|
||||
--click-repeat-interval) return ;;
|
||||
--config-file) _files ;;
|
||||
--config-default-files) return ;;
|
||||
--confirm-close-surface) return ;;
|
||||
--quit-after-last-window-closed) return ;;
|
||||
--quit-after-last-window-closed-delay) return ;;
|
||||
--initial-window) return ;;
|
||||
--quick-terminal-position) mapfile -t COMPREPLY < <( compgen -W "top bottom left right" -- "$cur" ); addSpaces ;;
|
||||
--quick-terminal-screen) mapfile -t COMPREPLY < <( compgen -W "main mouse macos-menu-bar" -- "$cur" ); addSpaces ;;
|
||||
--quick-terminal-animation-duration) return ;;
|
||||
--shell-integration) mapfile -t COMPREPLY < <( compgen -W "none detect bash elvish fish zsh" -- "$cur" ); addSpaces ;;
|
||||
--shell-integration-features) mapfile -t COMPREPLY < <( compgen -W "cursor no-cursor sudo no-sudo title no-title" -- "$cur" ); addSpaces ;;
|
||||
--osc-color-report-format) mapfile -t COMPREPLY < <( compgen -W "none 8-bit 16-bit" -- "$cur" ); addSpaces ;;
|
||||
--vt-kam-allowed) return ;;
|
||||
--custom-shader) _files ;;
|
||||
--custom-shader-animation) mapfile -t COMPREPLY < <( compgen -W "false true always" -- "$cur" ); addSpaces ;;
|
||||
--macos-non-native-fullscreen) mapfile -t COMPREPLY < <( compgen -W "false true visible-menu" -- "$cur" ); addSpaces ;;
|
||||
--macos-titlebar-style) mapfile -t COMPREPLY < <( compgen -W "native transparent tabs hidden" -- "$cur" ); addSpaces ;;
|
||||
--macos-titlebar-proxy-icon) mapfile -t COMPREPLY < <( compgen -W "visible hidden" -- "$cur" ); addSpaces ;;
|
||||
--macos-option-as-alt) return ;;
|
||||
--macos-window-shadow) return ;;
|
||||
--macos-auto-secure-input) return ;;
|
||||
--macos-secure-input-indication) return ;;
|
||||
--linux-cgroup) mapfile -t COMPREPLY < <( compgen -W "never always single-instance" -- "$cur" ); addSpaces ;;
|
||||
--linux-cgroup-memory-limit) return ;;
|
||||
--linux-cgroup-processes-limit) return ;;
|
||||
--linux-cgroup-hard-fail) return ;;
|
||||
--gtk-single-instance) mapfile -t COMPREPLY < <( compgen -W "desktop false true" -- "$cur" ); addSpaces ;;
|
||||
--gtk-titlebar) return ;;
|
||||
--gtk-tabs-location) mapfile -t COMPREPLY < <( compgen -W "top bottom left right hidden" -- "$cur" ); addSpaces ;;
|
||||
--adw-toolbar-style) mapfile -t COMPREPLY < <( compgen -W "flat raised raised-border" -- "$cur" ); addSpaces ;;
|
||||
--gtk-wide-tabs) return ;;
|
||||
--gtk-adwaita) return ;;
|
||||
--desktop-notifications) return ;;
|
||||
--bold-is-bright) return ;;
|
||||
--term) return ;;
|
||||
--enquiry-response) return ;;
|
||||
--auto-update) mapfile -t COMPREPLY < <( compgen -W "off check download" -- "$cur" ); addSpaces ;;
|
||||
--auto-update-channel) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$config" -- "$cur" ) ;;
|
||||
esac
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
list_fonts="--family= --style= '--bold ' '--italic ' --help"
|
||||
list_keybinds="'--default ' '--docs ' '--plain ' --help"
|
||||
list_themes="'--path ' '--plain ' --help"
|
||||
list_actions="'--docs ' --help"
|
||||
show_config="'--default ' '--changes-only ' '--docs ' --help"
|
||||
validate_config="--config-file= --help"
|
||||
|
||||
_handleActions() {
|
||||
case "${COMP_WORDS[1]}" in
|
||||
+list-fonts)
|
||||
case $prev in
|
||||
--family) return;;
|
||||
--style) return;;
|
||||
--bold) return ;;
|
||||
--italic) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$list_fonts" -- "$cur" ) ;;
|
||||
esac
|
||||
;;
|
||||
+list-keybinds)
|
||||
case $prev in
|
||||
--default) return ;;
|
||||
--docs) return ;;
|
||||
--plain) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$list_keybinds" -- "$cur" ) ;;
|
||||
esac
|
||||
;;
|
||||
+list-themes)
|
||||
case $prev in
|
||||
--path) return ;;
|
||||
--plain) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$list_themes" -- "$cur" ) ;;
|
||||
esac
|
||||
;;
|
||||
+list-actions)
|
||||
case $prev in
|
||||
--docs) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$list_actions" -- "$cur" ) ;;
|
||||
esac
|
||||
;;
|
||||
+show-config)
|
||||
case $prev in
|
||||
--default) return ;;
|
||||
--changes-only) return ;;
|
||||
--docs) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$show_config" -- "$cur" ) ;;
|
||||
esac
|
||||
;;
|
||||
+validate-config)
|
||||
case $prev in
|
||||
--config-file) return ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "$validate_config" -- "$cur" ) ;;
|
||||
esac
|
||||
;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "--help" -- "$cur" ) ;;
|
||||
esac
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
topLevel="-e"
|
||||
topLevel+=" --help"
|
||||
topLevel+=" --version"
|
||||
topLevel+=" +list-fonts"
|
||||
topLevel+=" +list-keybinds"
|
||||
topLevel+=" +list-themes"
|
||||
topLevel+=" +list-colors"
|
||||
topLevel+=" +list-actions"
|
||||
topLevel+=" +show-config"
|
||||
topLevel+=" +validate-config"
|
||||
topLevel+=" +crash-report"
|
||||
|
||||
_ghostty() {
|
||||
cur=""; prev=""; prevWasEq=false; COMPREPLY=()
|
||||
ghostty="$1"
|
||||
|
||||
# script assumes default COMP_WORDBREAKS of roughly $' \t\n"\'><=;|&(:'
|
||||
# if = is missing this script will degrade to matching on keys only.
|
||||
# eg: --key=
|
||||
# this can be improved if needed see: https://github.com/ghostty-org/ghostty/discussions/2994
|
||||
|
||||
if [ "$2" = "=" ]; then cur=""
|
||||
else cur="$2"
|
||||
fi
|
||||
|
||||
if [ "$3" = "=" ]; then prev="${COMP_WORDS[COMP_CWORD-2]}"; prevWasEq=true;
|
||||
else prev="${COMP_WORDS[COMP_CWORD-1]}"
|
||||
fi
|
||||
|
||||
# current completion is double quoted add a space so the curor progresses
|
||||
if [[ "$2" == \"*\" ]]; then
|
||||
COMPREPLY=( "$cur " );
|
||||
return;
|
||||
fi
|
||||
|
||||
case "$COMP_CWORD" in
|
||||
1)
|
||||
case "${COMP_WORDS[1]}" in
|
||||
-e | --help | --version) return 0 ;;
|
||||
--*) _handleConfig ;;
|
||||
*) mapfile -t COMPREPLY < <( compgen -W "${topLevel}" -- "$cur" ); addSpaces ;;
|
||||
esac
|
||||
;;
|
||||
*)
|
||||
case "$prev" in
|
||||
-e | --help | --version) return 0 ;;
|
||||
*)
|
||||
if [[ "=" != "${COMP_WORDS[COMP_CWORD]}" && $prevWasEq != true ]]; then
|
||||
# must be completing with a space after the key eg: '--<key> '
|
||||
# clear out prev so we don't run any of the key specific completions
|
||||
prev=""
|
||||
fi
|
||||
|
||||
case "${COMP_WORDS[1]}" in
|
||||
--*) _handleConfig ;;
|
||||
+*) _handleActions ;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
esac
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
complete -o nospace -o bashdefault -F _ghostty ghostty
|
17
bin/share/bat/syntaxes/ghostty.sublime-syntax
Normal file
17
bin/share/bat/syntaxes/ghostty.sublime-syntax
Normal file
|
@ -0,0 +1,17 @@
|
|||
%YAML 1.2
|
||||
---
|
||||
# See http://www.sublimetext.com/docs/syntax.html
|
||||
name: Ghostty Config
|
||||
file_extensions:
|
||||
- ghostty
|
||||
scope: source.ghostty
|
||||
|
||||
contexts:
|
||||
main:
|
||||
# Comments
|
||||
- match: '^\s*#.*$'
|
||||
scope: comment.line.number-sign.ghostty
|
||||
|
||||
# Keywords
|
||||
- match: '\b(font-family|font-family-bold|font-family-italic|font-family-bold-italic|font-style|font-style-bold|font-style-italic|font-style-bold-italic|font-synthetic-style|font-feature|font-size|font-variation|font-variation-bold|font-variation-italic|font-variation-bold-italic|font-codepoint-map|font-thicken|adjust-cell-width|adjust-cell-height|adjust-font-baseline|adjust-underline-position|adjust-underline-thickness|adjust-strikethrough-position|adjust-strikethrough-thickness|adjust-overline-position|adjust-overline-thickness|adjust-cursor-thickness|adjust-box-thickness|grapheme-width-method|freetype-load-flags|theme|background|foreground|selection-foreground|selection-background|selection-invert-fg-bg|minimum-contrast|palette|cursor-color|cursor-invert-fg-bg|cursor-opacity|cursor-style|cursor-style-blink|cursor-text|cursor-click-to-move|mouse-hide-while-typing|mouse-shift-capture|mouse-scroll-multiplier|background-opacity|background-blur-radius|unfocused-split-opacity|unfocused-split-fill|command|initial-command|wait-after-command|abnormal-command-exit-runtime|scrollback-limit|link|link-url|fullscreen|title|class|x11-instance-name|working-directory|keybind|window-padding-x|window-padding-y|window-padding-balance|window-padding-color|window-vsync|window-inherit-working-directory|window-inherit-font-size|window-decoration|window-title-font-family|window-theme|window-colorspace|window-height|window-width|window-save-state|window-step-resize|window-new-tab-position|resize-overlay|resize-overlay-position|resize-overlay-duration|focus-follows-mouse|clipboard-read|clipboard-write|clipboard-trim-trailing-spaces|clipboard-paste-protection|clipboard-paste-bracketed-safe|image-storage-limit|copy-on-select|click-repeat-interval|config-file|config-default-files|confirm-close-surface|quit-after-last-window-closed|quit-after-last-window-closed-delay|initial-window|quick-terminal-position|quick-terminal-screen|quick-terminal-animation-duration|shell-integration|shell-integration-features|osc-color-report-format|vt-kam-allowed|custom-shader|custom-shader-animation|macos-non-native-fullscreen|macos-titlebar-style|macos-titlebar-proxy-icon|macos-option-as-alt|macos-window-shadow|macos-auto-secure-input|macos-secure-input-indication|linux-cgroup|linux-cgroup-memory-limit|linux-cgroup-processes-limit|linux-cgroup-hard-fail|gtk-single-instance|gtk-titlebar|gtk-tabs-location|adw-toolbar-style|gtk-wide-tabs|gtk-adwaita|desktop-notifications|bold-is-bright|term|enquiry-response|auto-update|auto-update-channel)\b'
|
||||
scope: keyword.other.ghostty
|
150
bin/share/fish/vendor_completions.d/ghostty.fish
Normal file
150
bin/share/fish/vendor_completions.d/ghostty.fish
Normal file
|
@ -0,0 +1,150 @@
|
|||
set -l commands "+list-fonts +list-keybinds +list-themes +list-colors +list-actions +show-config +validate-config +crash-report"
|
||||
complete -c ghostty -f
|
||||
complete -c ghostty -s e -l help -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l version -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-family -r -f -a "(ghostty +list-fonts | grep '^[A-Z]')"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-family-bold -r -f -a "(ghostty +list-fonts | grep '^[A-Z]')"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-family-italic -r -f -a "(ghostty +list-fonts | grep '^[A-Z]')"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-family-bold-italic -r -f -a "(ghostty +list-fonts | grep '^[A-Z]')"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-style -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-style-bold -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-style-italic -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-style-bold-italic -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-synthetic-style -r -f -a "bold no-bold italic no-italic bold-italic no-bold-italic"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-feature -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-size -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-variation -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-variation-bold -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-variation-italic -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-variation-bold-italic -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-codepoint-map -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l font-thicken -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-cell-width -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-cell-height -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-font-baseline -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-underline-position -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-underline-thickness -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-strikethrough-position -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-strikethrough-thickness -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-overline-position -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-overline-thickness -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-cursor-thickness -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adjust-box-thickness -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l grapheme-width-method -r -f -a "legacy unicode"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l freetype-load-flags -r -f -a "hinting no-hinting force-autohint no-force-autohint monochrome no-monochrome autohint no-autohint"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l theme -r -f -a "(ghostty +list-themes | sed -E 's/^(.*) \(.*\$/\1/')"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l background -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l foreground -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l selection-foreground -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l selection-background -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l selection-invert-fg-bg -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l minimum-contrast -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l palette -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-color -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-invert-fg-bg -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-opacity -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-style -r -f -a "bar block underline block_hollow"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-style-blink -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-text -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l cursor-click-to-move -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l mouse-hide-while-typing -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l mouse-shift-capture -r -f -a "false true always never"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l mouse-scroll-multiplier -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l background-opacity -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l background-blur-radius -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l unfocused-split-opacity -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l unfocused-split-fill -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l command -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l initial-command -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l wait-after-command -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l abnormal-command-exit-runtime -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l scrollback-limit -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l link -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l link-url -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l fullscreen -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l title -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l class -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l x11-instance-name -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l working-directory -r -f -k -a "(__fish_complete_directories)"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l keybind -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-padding-x -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-padding-y -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-padding-balance -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-padding-color -r -f -a "background extend extend-always"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-vsync -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-inherit-working-directory -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-inherit-font-size -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-decoration -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-title-font-family -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-theme -r -f -a "auto system light dark ghostty"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-colorspace -r -f -a "srgb display-p3"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-height -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-width -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-save-state -r -f -a "default never always"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-step-resize -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l window-new-tab-position -r -f -a "current end"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l resize-overlay -r -f -a "always never after-first"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l resize-overlay-position -r -f -a "center top-left top-center top-right bottom-left bottom-center bottom-right"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l resize-overlay-duration -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l focus-follows-mouse -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l clipboard-read -r -f -a "allow deny ask"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l clipboard-write -r -f -a "allow deny ask"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l clipboard-trim-trailing-spaces -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l clipboard-paste-protection -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l clipboard-paste-bracketed-safe -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l image-storage-limit -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l copy-on-select -r -f -a "false true clipboard"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l click-repeat-interval -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l config-file -r -F
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l config-default-files -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l confirm-close-surface -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l quit-after-last-window-closed -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l quit-after-last-window-closed-delay -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l initial-window -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l quick-terminal-position -r -f -a "top bottom left right"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l quick-terminal-screen -r -f -a "main mouse macos-menu-bar"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l quick-terminal-animation-duration -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l shell-integration -r -f -a "none detect bash elvish fish zsh"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l shell-integration-features -r -f -a "cursor no-cursor sudo no-sudo title no-title"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l osc-color-report-format -r -f -a "none 8-bit 16-bit"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l vt-kam-allowed -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l custom-shader -r -F
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l custom-shader-animation -r -f -a "false true always"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-non-native-fullscreen -r -f -a "false true visible-menu"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-titlebar-style -r -f -a "native transparent tabs hidden"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-titlebar-proxy-icon -r -f -a "visible hidden"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-option-as-alt -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-window-shadow -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-auto-secure-input -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l macos-secure-input-indication -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l linux-cgroup -r -f -a "never always single-instance"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l linux-cgroup-memory-limit -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l linux-cgroup-processes-limit -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l linux-cgroup-hard-fail -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l gtk-single-instance -r -f -a "desktop false true"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l gtk-titlebar -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l gtk-tabs-location -r -f -a "top bottom left right hidden"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l adw-toolbar-style -r -f -a "flat raised raised-border"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l gtk-wide-tabs -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l gtk-adwaita -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l desktop-notifications -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l bold-is-bright -f -a "true false"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l term -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l enquiry-response -r -f
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l auto-update -r -f -a "off check download"
|
||||
complete -c ghostty -n "not __fish_seen_subcommand_from $commands" -l auto-update-channel -r -f
|
||||
complete -c ghostty -n "string match -q -- '+*' (commandline -pt)" -f -a "+list-fonts +list-keybinds +list-themes +list-colors +list-actions +show-config +validate-config +crash-report"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-fonts" -l family -r -f
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-fonts" -l style -r -f
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-fonts" -l bold -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-fonts" -l italic -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-keybinds" -l default -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-keybinds" -l docs -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-keybinds" -l plain -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-themes" -l path -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-themes" -l plain -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +list-actions" -l docs -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +show-config" -l default -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +show-config" -l changes-only -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +show-config" -l docs -f -a "true false"
|
||||
complete -c ghostty -n "__fish_seen_subcommand_from +validate-config" -l config-file -r -F
|
2244
bin/share/ghostty/doc/ghostty.1.html
Normal file
2244
bin/share/ghostty/doc/ghostty.1.html
Normal file
File diff suppressed because it is too large
Load diff
2291
bin/share/ghostty/doc/ghostty.1.md
Normal file
2291
bin/share/ghostty/doc/ghostty.1.md
Normal file
File diff suppressed because it is too large
Load diff
2431
bin/share/ghostty/doc/ghostty.5.html
Normal file
2431
bin/share/ghostty/doc/ghostty.5.html
Normal file
File diff suppressed because it is too large
Load diff
2517
bin/share/ghostty/doc/ghostty.5.md
Normal file
2517
bin/share/ghostty/doc/ghostty.5.md
Normal file
File diff suppressed because it is too large
Load diff
386
bin/share/ghostty/shell-integration/bash/bash-preexec.sh
Normal file
386
bin/share/ghostty/shell-integration/bash/bash-preexec.sh
Normal file
|
@ -0,0 +1,386 @@
|
|||
# bash-preexec.sh -- Bash support for ZSH-like 'preexec' and 'precmd' functions.
|
||||
# https://github.com/rcaloras/bash-preexec
|
||||
#
|
||||
#
|
||||
# 'preexec' functions are executed before each interactive command is
|
||||
# executed, with the interactive command as its argument. The 'precmd'
|
||||
# function is executed before each prompt is displayed.
|
||||
#
|
||||
# Author: Ryan Caloras (ryan@bashhub.com)
|
||||
# Forked from Original Author: Glyph Lefkowitz
|
||||
#
|
||||
# V0.5.0
|
||||
#
|
||||
|
||||
# General Usage:
|
||||
#
|
||||
# 1. Source this file at the end of your bash profile so as not to interfere
|
||||
# with anything else that's using PROMPT_COMMAND.
|
||||
#
|
||||
# 2. Add any precmd or preexec functions by appending them to their arrays:
|
||||
# e.g.
|
||||
# precmd_functions+=(my_precmd_function)
|
||||
# precmd_functions+=(some_other_precmd_function)
|
||||
#
|
||||
# preexec_functions+=(my_preexec_function)
|
||||
#
|
||||
# 3. Consider changing anything using the DEBUG trap or PROMPT_COMMAND
|
||||
# to use preexec and precmd instead. Preexisting usages will be
|
||||
# preserved, but doing so manually may be less surprising.
|
||||
#
|
||||
# Note: This module requires two Bash features which you must not otherwise be
|
||||
# using: the "DEBUG" trap, and the "PROMPT_COMMAND" variable. If you override
|
||||
# either of these after bash-preexec has been installed it will most likely break.
|
||||
|
||||
# Tell shellcheck what kind of file this is.
|
||||
# shellcheck shell=bash
|
||||
|
||||
# Make sure this is bash that's running and return otherwise.
|
||||
# Use POSIX syntax for this line:
|
||||
if [ -z "${BASH_VERSION-}" ]; then
|
||||
return 1;
|
||||
fi
|
||||
|
||||
# We only support Bash 3.1+.
|
||||
# Note: BASH_VERSINFO is first available in Bash-2.0.
|
||||
if [[ -z "${BASH_VERSINFO-}" ]] || (( BASH_VERSINFO[0] < 3 || (BASH_VERSINFO[0] == 3 && BASH_VERSINFO[1] < 1) )); then
|
||||
return 1
|
||||
fi
|
||||
|
||||
# Avoid duplicate inclusion
|
||||
if [[ -n "${bash_preexec_imported:-}" || -n "${__bp_imported:-}" ]]; then
|
||||
return 0
|
||||
fi
|
||||
bash_preexec_imported="defined"
|
||||
|
||||
# WARNING: This variable is no longer used and should not be relied upon.
|
||||
# Use ${bash_preexec_imported} instead.
|
||||
# shellcheck disable=SC2034
|
||||
__bp_imported="${bash_preexec_imported}"
|
||||
|
||||
# Should be available to each precmd and preexec
|
||||
# functions, should they want it. $? and $_ are available as $? and $_, but
|
||||
# $PIPESTATUS is available only in a copy, $BP_PIPESTATUS.
|
||||
# TODO: Figure out how to restore PIPESTATUS before each precmd or preexec
|
||||
# function.
|
||||
__bp_last_ret_value="$?"
|
||||
BP_PIPESTATUS=("${PIPESTATUS[@]}")
|
||||
__bp_last_argument_prev_command="$_"
|
||||
|
||||
__bp_inside_precmd=0
|
||||
__bp_inside_preexec=0
|
||||
|
||||
# Initial PROMPT_COMMAND string that is removed from PROMPT_COMMAND post __bp_install
|
||||
__bp_install_string=$'__bp_trap_string="$(trap -p DEBUG)"\ntrap - DEBUG\n__bp_install'
|
||||
|
||||
# Fails if any of the given variables are readonly
|
||||
# Reference https://stackoverflow.com/a/4441178
|
||||
__bp_require_not_readonly() {
|
||||
local var
|
||||
for var; do
|
||||
if ! ( unset "$var" 2> /dev/null ); then
|
||||
echo "bash-preexec requires write access to ${var}" >&2
|
||||
return 1
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
# Remove ignorespace and or replace ignoreboth from HISTCONTROL
|
||||
# so we can accurately invoke preexec with a command from our
|
||||
# history even if it starts with a space.
|
||||
__bp_adjust_histcontrol() {
|
||||
local histcontrol
|
||||
histcontrol="${HISTCONTROL:-}"
|
||||
histcontrol="${histcontrol//ignorespace}"
|
||||
# Replace ignoreboth with ignoredups
|
||||
if [[ "$histcontrol" == *"ignoreboth"* ]]; then
|
||||
histcontrol="ignoredups:${histcontrol//ignoreboth}"
|
||||
fi;
|
||||
export HISTCONTROL="$histcontrol"
|
||||
}
|
||||
|
||||
# This variable describes whether we are currently in "interactive mode";
|
||||
# i.e. whether this shell has just executed a prompt and is waiting for user
|
||||
# input. It documents whether the current command invoked by the trace hook is
|
||||
# run interactively by the user; it's set immediately after the prompt hook,
|
||||
# and unset as soon as the trace hook is run.
|
||||
__bp_preexec_interactive_mode=""
|
||||
|
||||
# These arrays are used to add functions to be run before, or after, prompts.
|
||||
declare -a precmd_functions
|
||||
declare -a preexec_functions
|
||||
|
||||
# Trims leading and trailing whitespace from $2 and writes it to the variable
|
||||
# name passed as $1
|
||||
__bp_trim_whitespace() {
|
||||
local var=${1:?} text=${2:-}
|
||||
text="${text#"${text%%[![:space:]]*}"}" # remove leading whitespace characters
|
||||
text="${text%"${text##*[![:space:]]}"}" # remove trailing whitespace characters
|
||||
printf -v "$var" '%s' "$text"
|
||||
}
|
||||
|
||||
|
||||
# Trims whitespace and removes any leading or trailing semicolons from $2 and
|
||||
# writes the resulting string to the variable name passed as $1. Used for
|
||||
# manipulating substrings in PROMPT_COMMAND
|
||||
__bp_sanitize_string() {
|
||||
local var=${1:?} text=${2:-} sanitized
|
||||
__bp_trim_whitespace sanitized "$text"
|
||||
sanitized=${sanitized%;}
|
||||
sanitized=${sanitized#;}
|
||||
__bp_trim_whitespace sanitized "$sanitized"
|
||||
printf -v "$var" '%s' "$sanitized"
|
||||
}
|
||||
|
||||
# This function is installed as part of the PROMPT_COMMAND;
|
||||
# It sets a variable to indicate that the prompt was just displayed,
|
||||
# to allow the DEBUG trap to know that the next command is likely interactive.
|
||||
__bp_interactive_mode() {
|
||||
__bp_preexec_interactive_mode="on";
|
||||
}
|
||||
|
||||
|
||||
# This function is installed as part of the PROMPT_COMMAND.
|
||||
# It will invoke any functions defined in the precmd_functions array.
|
||||
__bp_precmd_invoke_cmd() {
|
||||
# Save the returned value from our last command, and from each process in
|
||||
# its pipeline. Note: this MUST be the first thing done in this function.
|
||||
# BP_PIPESTATUS may be unused, ignore
|
||||
# shellcheck disable=SC2034
|
||||
|
||||
__bp_last_ret_value="$?" BP_PIPESTATUS=("${PIPESTATUS[@]}")
|
||||
|
||||
# Don't invoke precmds if we are inside an execution of an "original
|
||||
# prompt command" by another precmd execution loop. This avoids infinite
|
||||
# recursion.
|
||||
if (( __bp_inside_precmd > 0 )); then
|
||||
return
|
||||
fi
|
||||
local __bp_inside_precmd=1
|
||||
|
||||
# Invoke every function defined in our function array.
|
||||
local precmd_function
|
||||
for precmd_function in "${precmd_functions[@]}"; do
|
||||
|
||||
# Only execute this function if it actually exists.
|
||||
# Test existence of functions with: declare -[Ff]
|
||||
if type -t "$precmd_function" 1>/dev/null; then
|
||||
__bp_set_ret_value "$__bp_last_ret_value" "$__bp_last_argument_prev_command"
|
||||
# Quote our function invocation to prevent issues with IFS
|
||||
"$precmd_function"
|
||||
fi
|
||||
done
|
||||
|
||||
__bp_set_ret_value "$__bp_last_ret_value"
|
||||
}
|
||||
|
||||
# Sets a return value in $?. We may want to get access to the $? variable in our
|
||||
# precmd functions. This is available for instance in zsh. We can simulate it in bash
|
||||
# by setting the value here.
|
||||
__bp_set_ret_value() {
|
||||
return ${1:+"$1"}
|
||||
}
|
||||
|
||||
__bp_in_prompt_command() {
|
||||
|
||||
local prompt_command_array IFS=$'\n;'
|
||||
read -rd '' -a prompt_command_array <<< "${PROMPT_COMMAND[*]:-}"
|
||||
|
||||
local trimmed_arg
|
||||
__bp_trim_whitespace trimmed_arg "${1:-}"
|
||||
|
||||
local command trimmed_command
|
||||
for command in "${prompt_command_array[@]:-}"; do
|
||||
__bp_trim_whitespace trimmed_command "$command"
|
||||
if [[ "$trimmed_command" == "$trimmed_arg" ]]; then
|
||||
return 0
|
||||
fi
|
||||
done
|
||||
|
||||
return 1
|
||||
}
|
||||
|
||||
# This function is installed as the DEBUG trap. It is invoked before each
|
||||
# interactive prompt display. Its purpose is to inspect the current
|
||||
# environment to attempt to detect if the current command is being invoked
|
||||
# interactively, and invoke 'preexec' if so.
|
||||
__bp_preexec_invoke_exec() {
|
||||
|
||||
# Save the contents of $_ so that it can be restored later on.
|
||||
# https://stackoverflow.com/questions/40944532/bash-preserve-in-a-debug-trap#40944702
|
||||
__bp_last_argument_prev_command="${1:-}"
|
||||
# Don't invoke preexecs if we are inside of another preexec.
|
||||
if (( __bp_inside_preexec > 0 )); then
|
||||
return
|
||||
fi
|
||||
local __bp_inside_preexec=1
|
||||
|
||||
# Checks if the file descriptor is not standard out (i.e. '1')
|
||||
# __bp_delay_install checks if we're in test. Needed for bats to run.
|
||||
# Prevents preexec from being invoked for functions in PS1
|
||||
if [[ ! -t 1 && -z "${__bp_delay_install:-}" ]]; then
|
||||
return
|
||||
fi
|
||||
|
||||
if [[ -n "${COMP_POINT:-}" || -n "${READLINE_POINT:-}" ]]; then
|
||||
# We're in the middle of a completer or a keybinding set up by "bind
|
||||
# -x". This obviously can't be an interactively issued command.
|
||||
return
|
||||
fi
|
||||
if [[ -z "${__bp_preexec_interactive_mode:-}" ]]; then
|
||||
# We're doing something related to displaying the prompt. Let the
|
||||
# prompt set the title instead of me.
|
||||
return
|
||||
else
|
||||
# If we're in a subshell, then the prompt won't be re-displayed to put
|
||||
# us back into interactive mode, so let's not set the variable back.
|
||||
# In other words, if you have a subshell like
|
||||
# (sleep 1; sleep 2)
|
||||
# You want to see the 'sleep 2' as a set_command_title as well.
|
||||
if [[ 0 -eq "${BASH_SUBSHELL:-}" ]]; then
|
||||
__bp_preexec_interactive_mode=""
|
||||
fi
|
||||
fi
|
||||
|
||||
if __bp_in_prompt_command "${BASH_COMMAND:-}"; then
|
||||
# If we're executing something inside our prompt_command then we don't
|
||||
# want to call preexec. Bash prior to 3.1 can't detect this at all :/
|
||||
__bp_preexec_interactive_mode=""
|
||||
return
|
||||
fi
|
||||
|
||||
local this_command
|
||||
this_command=$(
|
||||
export LC_ALL=C
|
||||
HISTTIMEFORMAT='' builtin history 1 | sed '1 s/^ *[0-9][0-9]*[* ] //'
|
||||
)
|
||||
|
||||
# Sanity check to make sure we have something to invoke our function with.
|
||||
if [[ -z "$this_command" ]]; then
|
||||
return
|
||||
fi
|
||||
|
||||
# Invoke every function defined in our function array.
|
||||
local preexec_function
|
||||
local preexec_function_ret_value
|
||||
local preexec_ret_value=0
|
||||
for preexec_function in "${preexec_functions[@]:-}"; do
|
||||
|
||||
# Only execute each function if it actually exists.
|
||||
# Test existence of function with: declare -[fF]
|
||||
if type -t "$preexec_function" 1>/dev/null; then
|
||||
__bp_set_ret_value "${__bp_last_ret_value:-}"
|
||||
# Quote our function invocation to prevent issues with IFS
|
||||
"$preexec_function" "$this_command"
|
||||
preexec_function_ret_value="$?"
|
||||
if [[ "$preexec_function_ret_value" != 0 ]]; then
|
||||
preexec_ret_value="$preexec_function_ret_value"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
# Restore the last argument of the last executed command, and set the return
|
||||
# value of the DEBUG trap to be the return code of the last preexec function
|
||||
# to return an error.
|
||||
# If `extdebug` is enabled a non-zero return value from any preexec function
|
||||
# will cause the user's command not to execute.
|
||||
# Run `shopt -s extdebug` to enable
|
||||
__bp_set_ret_value "$preexec_ret_value" "$__bp_last_argument_prev_command"
|
||||
}
|
||||
|
||||
__bp_install() {
|
||||
# Exit if we already have this installed.
|
||||
if [[ "${PROMPT_COMMAND[*]:-}" == *"__bp_precmd_invoke_cmd"* ]]; then
|
||||
return 1;
|
||||
fi
|
||||
|
||||
trap '__bp_preexec_invoke_exec "$_"' DEBUG
|
||||
|
||||
# Preserve any prior DEBUG trap as a preexec function
|
||||
local prior_trap
|
||||
# we can't easily do this with variable expansion. Leaving as sed command.
|
||||
# shellcheck disable=SC2001
|
||||
prior_trap=$(sed "s/[^']*'\(.*\)'[^']*/\1/" <<<"${__bp_trap_string:-}")
|
||||
unset __bp_trap_string
|
||||
if [[ -n "$prior_trap" ]]; then
|
||||
eval '__bp_original_debug_trap() {
|
||||
'"$prior_trap"'
|
||||
}'
|
||||
preexec_functions+=(__bp_original_debug_trap)
|
||||
fi
|
||||
|
||||
# Adjust our HISTCONTROL Variable if needed.
|
||||
#
|
||||
# GHOSTTY: Don't modify HISTCONTROL. This hack is only needed to improve the
|
||||
# accuracy of the command argument passed to the preexec functions, and we
|
||||
# don't use that argument in our bash shell integration script (and nor does
|
||||
# the __bp_original_debug_trap function above, which is the only other active
|
||||
# preexec function).
|
||||
#__bp_adjust_histcontrol
|
||||
|
||||
# Issue #25. Setting debug trap for subshells causes sessions to exit for
|
||||
# backgrounded subshell commands (e.g. (pwd)& ). Believe this is a bug in Bash.
|
||||
#
|
||||
# Disabling this by default. It can be enabled by setting this variable.
|
||||
if [[ -n "${__bp_enable_subshells:-}" ]]; then
|
||||
|
||||
# Set so debug trap will work be invoked in subshells.
|
||||
set -o functrace > /dev/null 2>&1
|
||||
shopt -s extdebug > /dev/null 2>&1
|
||||
fi;
|
||||
|
||||
local existing_prompt_command
|
||||
# Remove setting our trap install string and sanitize the existing prompt command string
|
||||
existing_prompt_command="${PROMPT_COMMAND:-}"
|
||||
# Edge case of appending to PROMPT_COMMAND
|
||||
existing_prompt_command="${existing_prompt_command//$__bp_install_string/:}" # no-op
|
||||
existing_prompt_command="${existing_prompt_command//$'\n':$'\n'/$'\n'}" # remove known-token only
|
||||
existing_prompt_command="${existing_prompt_command//$'\n':;/$'\n'}" # remove known-token only
|
||||
__bp_sanitize_string existing_prompt_command "$existing_prompt_command"
|
||||
if [[ "${existing_prompt_command:-:}" == ":" ]]; then
|
||||
existing_prompt_command=
|
||||
fi
|
||||
|
||||
# Install our hooks in PROMPT_COMMAND to allow our trap to know when we've
|
||||
# actually entered something.
|
||||
PROMPT_COMMAND='__bp_precmd_invoke_cmd'
|
||||
PROMPT_COMMAND+=${existing_prompt_command:+$'\n'$existing_prompt_command}
|
||||
if (( BASH_VERSINFO[0] > 5 || (BASH_VERSINFO[0] == 5 && BASH_VERSINFO[1] >= 1) )); then
|
||||
PROMPT_COMMAND+=('__bp_interactive_mode')
|
||||
else
|
||||
# shellcheck disable=SC2179 # PROMPT_COMMAND is not an array in bash <= 5.0
|
||||
PROMPT_COMMAND+=$'\n__bp_interactive_mode'
|
||||
fi
|
||||
|
||||
# Add two functions to our arrays for convenience
|
||||
# of definition.
|
||||
precmd_functions+=(precmd)
|
||||
preexec_functions+=(preexec)
|
||||
|
||||
# Invoke our two functions manually that were added to $PROMPT_COMMAND
|
||||
__bp_precmd_invoke_cmd
|
||||
__bp_interactive_mode
|
||||
}
|
||||
|
||||
# Sets an installation string as part of our PROMPT_COMMAND to install
|
||||
# after our session has started. This allows bash-preexec to be included
|
||||
# at any point in our bash profile.
|
||||
__bp_install_after_session_init() {
|
||||
# bash-preexec needs to modify these variables in order to work correctly
|
||||
# if it can't, just stop the installation
|
||||
__bp_require_not_readonly PROMPT_COMMAND HISTCONTROL HISTTIMEFORMAT || return
|
||||
|
||||
local sanitized_prompt_command
|
||||
__bp_sanitize_string sanitized_prompt_command "${PROMPT_COMMAND:-}"
|
||||
if [[ -n "$sanitized_prompt_command" ]]; then
|
||||
# shellcheck disable=SC2178 # PROMPT_COMMAND is not an array in bash <= 5.0
|
||||
PROMPT_COMMAND=${sanitized_prompt_command}$'\n'
|
||||
fi;
|
||||
# shellcheck disable=SC2179 # PROMPT_COMMAND is not an array in bash <= 5.0
|
||||
PROMPT_COMMAND+=${__bp_install_string}
|
||||
}
|
||||
|
||||
# Run our install so long as we're not delaying it.
|
||||
if [[ -z "${__bp_delay_install:-}" ]]; then
|
||||
__bp_install_after_session_init
|
||||
fi;
|
176
bin/share/ghostty/shell-integration/bash/ghostty.bash
Normal file
176
bin/share/ghostty/shell-integration/bash/ghostty.bash
Normal file
|
@ -0,0 +1,176 @@
|
|||
# This is originally based on the recommended bash integration from
|
||||
# the semantic prompts proposal as well as some logic from Kitty's
|
||||
# bash integration.
|
||||
#
|
||||
# I'm not a bash expert so this probably has some major issues but for
|
||||
# my simple bash usage this is working. If a bash expert wants to
|
||||
# improve this please do!
|
||||
|
||||
# We need to be in interactive mode and we need to have the Ghostty
|
||||
# resources dir set which also tells us we're running in Ghostty.
|
||||
if [[ "$-" != *i* ]] ; then builtin return; fi
|
||||
if [ -z "$GHOSTTY_RESOURCES_DIR" ]; then builtin return; fi
|
||||
|
||||
# When automatic shell integration is active, we need to manually
|
||||
# load the normal bash startup files based on the injected state.
|
||||
if [ -n "$GHOSTTY_BASH_INJECT" ]; then
|
||||
builtin declare ghostty_bash_inject="$GHOSTTY_BASH_INJECT"
|
||||
builtin unset GHOSTTY_BASH_INJECT ENV
|
||||
|
||||
# At this point, we're in POSIX mode and rely on the injected
|
||||
# flags to guide is through the rest of the startup sequence.
|
||||
|
||||
# POSIX mode was requested by the user so there's nothing
|
||||
# more to do that optionally source their original $ENV.
|
||||
# No other startup files are read, per the standard.
|
||||
if [[ "$ghostty_bash_inject" == *"--posix"* ]]; then
|
||||
if [ -n "$GHOSTTY_BASH_ENV" ]; then
|
||||
builtin source "$GHOSTTY_BASH_ENV"
|
||||
builtin export ENV="$GHOSTTY_BASH_ENV"
|
||||
fi
|
||||
else
|
||||
# Restore bash's default 'posix' behavior. Also reset 'inherit_errexit',
|
||||
# which doesn't happen as part of the 'posix' reset.
|
||||
builtin set +o posix
|
||||
builtin shopt -u inherit_errexit 2>/dev/null
|
||||
|
||||
# Unexport HISTFILE if it was set by the shell integration code.
|
||||
if [[ -n "$GHOSTTY_BASH_UNEXPORT_HISTFILE" ]]; then
|
||||
builtin export -n HISTFILE
|
||||
builtin unset GHOSTTY_BASH_UNEXPORT_HISTFILE
|
||||
fi
|
||||
|
||||
# Manually source the startup files, respecting the injected flags like
|
||||
# --norc and --noprofile that we parsed with the shell integration code.
|
||||
#
|
||||
# See also: run_startup_files() in shell.c in the Bash source code
|
||||
if builtin shopt -q login_shell; then
|
||||
if [[ $ghostty_bash_inject != *"--noprofile"* ]]; then
|
||||
[ -r /etc/profile ] && builtin source "/etc/profile"
|
||||
for rcfile in "$HOME/.bash_profile" "$HOME/.bash_login" "$HOME/.profile"; do
|
||||
[ -r "$rcfile" ] && { builtin source "$rcfile"; break; }
|
||||
done
|
||||
fi
|
||||
else
|
||||
if [[ $ghostty_bash_inject != *"--norc"* ]]; then
|
||||
# The location of the system bashrc is determined at bash build
|
||||
# time via -DSYS_BASHRC and can therefore vary across distros:
|
||||
# Arch, Debian, Ubuntu use /etc/bash.bashrc
|
||||
# Fedora uses /etc/bashrc sourced from ~/.bashrc instead of SYS_BASHRC
|
||||
# Void Linux uses /etc/bash/bashrc
|
||||
# Nixos uses /etc/bashrc
|
||||
for rcfile in /etc/bash.bashrc /etc/bash/bashrc /etc/bashrc; do
|
||||
[ -r "$rcfile" ] && { builtin source "$rcfile"; break; }
|
||||
done
|
||||
if [[ -z "$GHOSTTY_BASH_RCFILE" ]]; then GHOSTTY_BASH_RCFILE="$HOME/.bashrc"; fi
|
||||
[ -r "$GHOSTTY_BASH_RCFILE" ] && builtin source "$GHOSTTY_BASH_RCFILE"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
builtin unset GHOSTTY_BASH_ENV GHOSTTY_BASH_RCFILE
|
||||
builtin unset ghostty_bash_inject rcfile
|
||||
fi
|
||||
|
||||
# Import bash-preexec, safe to do multiple times
|
||||
builtin source "$GHOSTTY_RESOURCES_DIR/shell-integration/bash/bash-preexec.sh"
|
||||
|
||||
# This is set to 1 when we're executing a command so that we don't
|
||||
# send prompt marks multiple times.
|
||||
_ghostty_executing=""
|
||||
_ghostty_last_reported_cwd=""
|
||||
|
||||
function __ghostty_get_current_command() {
|
||||
builtin local last_cmd
|
||||
# shellcheck disable=SC1007
|
||||
last_cmd=$(HISTTIMEFORMAT= builtin history 1)
|
||||
last_cmd="${last_cmd#*[[:digit:]]*[[:space:]]}" # remove leading history number
|
||||
last_cmd="${last_cmd#"${last_cmd%%[![:space:]]*}"}" # remove remaining leading whitespace
|
||||
builtin printf "\e]2;%s\a" "${last_cmd//[[:cntrl:]]}" # remove any control characters
|
||||
}
|
||||
|
||||
function __ghostty_precmd() {
|
||||
local ret="$?"
|
||||
if test "$_ghostty_executing" != "0"; then
|
||||
_GHOSTTY_SAVE_PS0="$PS0"
|
||||
_GHOSTTY_SAVE_PS1="$PS1"
|
||||
_GHOSTTY_SAVE_PS2="$PS2"
|
||||
|
||||
# Marks
|
||||
PS1=$PS1'\[\e]133;B\a\]'
|
||||
PS2=$PS2'\[\e]133;B\a\]'
|
||||
|
||||
# bash doesn't redraw the leading lines in a multiline prompt so
|
||||
# mark the last line as a secondary prompt (k=s) to prevent the
|
||||
# preceding lines from being erased by ghostty after a resize.
|
||||
if [[ "${PS1}" == *"\n"* || "${PS1}" == *$'\n'* ]]; then
|
||||
PS1=$PS1'\[\e]133;A;k=s\a\]'
|
||||
fi
|
||||
|
||||
# Cursor
|
||||
if test "$GHOSTTY_SHELL_INTEGRATION_NO_CURSOR" != "1"; then
|
||||
PS1=$PS1'\[\e[5 q\]'
|
||||
PS0=$PS0'\[\e[0 q\]'
|
||||
fi
|
||||
|
||||
# Sudo
|
||||
if [[ "$GHOSTTY_SHELL_INTEGRATION_NO_SUDO" != "1" ]] && [[ -n "$TERMINFO" ]]; then
|
||||
# Wrap `sudo` command to ensure Ghostty terminfo is preserved
|
||||
# shellcheck disable=SC2317
|
||||
sudo() {
|
||||
builtin local sudo_has_sudoedit_flags="no"
|
||||
for arg in "$@"; do
|
||||
# Check if argument is '-e' or '--edit' (sudoedit flags)
|
||||
if [[ "$arg" == "-e" || $arg == "--edit" ]]; then
|
||||
sudo_has_sudoedit_flags="yes"
|
||||
builtin break
|
||||
fi
|
||||
# Check if argument is neither an option nor a key-value pair
|
||||
if [[ "$arg" != -* && "$arg" != *=* ]]; then
|
||||
builtin break
|
||||
fi
|
||||
done
|
||||
if [[ "$sudo_has_sudoedit_flags" == "yes" ]]; then
|
||||
builtin command sudo "$@";
|
||||
else
|
||||
builtin command sudo TERMINFO="$TERMINFO" "$@";
|
||||
fi
|
||||
}
|
||||
fi
|
||||
|
||||
if [[ "$GHOSTTY_SHELL_INTEGRATION_NO_TITLE" != 1 ]]; then
|
||||
# Command and working directory
|
||||
# shellcheck disable=SC2016
|
||||
PS0=$PS0'$(__ghostty_get_current_command)'
|
||||
PS1=$PS1'\[\e]2;$PWD\a\]'
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "$_ghostty_executing" != ""; then
|
||||
# End of current command. Report its status.
|
||||
builtin printf "\e]133;D;%s;aid=%s\a" "$ret" "$BASHPID"
|
||||
fi
|
||||
|
||||
# unfortunately bash provides no hooks to detect cwd changes
|
||||
# in particular this means cwd reporting will not happen for a
|
||||
# command like cd /test && cat. PS0 is evaluated before cd is run.
|
||||
if [[ "$_ghostty_last_reported_cwd" != "$PWD" ]]; then
|
||||
_ghostty_last_reported_cwd="$PWD"
|
||||
builtin printf "\e]7;kitty-shell-cwd://%s%s\a" "$HOSTNAME" "$PWD"
|
||||
fi
|
||||
|
||||
# Fresh line and start of prompt.
|
||||
builtin printf "\e]133;A;aid=%s\a" "$BASHPID"
|
||||
_ghostty_executing=0
|
||||
}
|
||||
|
||||
function __ghostty_preexec() {
|
||||
PS0="$_GHOSTTY_SAVE_PS0"
|
||||
PS1="$_GHOSTTY_SAVE_PS1"
|
||||
PS2="$_GHOSTTY_SAVE_PS2"
|
||||
builtin printf "\e]133;C;\a"
|
||||
_ghostty_executing=1
|
||||
}
|
||||
|
||||
preexec_functions+=(__ghostty_preexec)
|
||||
precmd_functions+=(__ghostty_precmd)
|
|
@ -0,0 +1,123 @@
|
|||
{
|
||||
fn restore-xdg-dirs {
|
||||
use str
|
||||
var integration-dir = $E:GHOSTTY_SHELL_INTEGRATION_XDG_DIR
|
||||
var xdg-dirs = [(str:split ':' $E:XDG_DATA_DIRS)]
|
||||
var len = (count $xdg-dirs)
|
||||
|
||||
var index = $nil
|
||||
range $len | each {|dir-index|
|
||||
if (eq $xdg-dirs[$dir-index] $integration-dir) {
|
||||
set index = $dir-index
|
||||
break
|
||||
}
|
||||
}
|
||||
if (eq $nil $index) { return } # will appear as an error
|
||||
|
||||
if (== 0 $index) {
|
||||
set xdg-dirs = $xdg-dirs[1..]
|
||||
} elif (== (- $len 1) $index) {
|
||||
set xdg-dirs = $xdg-dirs[0..(- $len 1)]
|
||||
} else {
|
||||
# no builtin function for this : )
|
||||
set xdg-dirs = [ (take $index $xdg-dirs) (drop (+ 1 $index) $xdg-dirs) ]
|
||||
}
|
||||
|
||||
if (== 0 (count $xdg-dirs)) {
|
||||
unset-env XDG_DATA_DIRS
|
||||
} else {
|
||||
set-env XDG_DATA_DIRS (str:join ':' $xdg-dirs)
|
||||
}
|
||||
unset-env GHOSTTY_SHELL_INTEGRATION_XDG_DIR
|
||||
}
|
||||
if (and (has-env GHOSTTY_SHELL_INTEGRATION_XDG_DIR) (has-env XDG_DATA_DIRS)) {
|
||||
restore-xdg-dirs
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
# helper used by `mark-*` functions
|
||||
fn set-prompt-state {|new| set-env __ghostty_prompt_state $new }
|
||||
|
||||
fn mark-prompt-start {
|
||||
if (not-eq prompt-start (constantly $E:__ghostty_prompt_state)) {
|
||||
printf "\e]133;D\a"
|
||||
}
|
||||
set-prompt-state 'prompt-start'
|
||||
printf "\e]133;A\a"
|
||||
}
|
||||
|
||||
fn mark-output-start {|_|
|
||||
set-prompt-state 'pre-exec'
|
||||
printf "\e]133;C\a"
|
||||
}
|
||||
|
||||
fn mark-output-end {|cmd-info|
|
||||
set-prompt-state 'post-exec'
|
||||
|
||||
var exit-status = 0
|
||||
|
||||
# in case of error: retrieve exit status,
|
||||
# unless does not exist (= builtin function failure), then default to 1
|
||||
if (not-eq $nil $cmd-info[error]) {
|
||||
set exit-status = 1
|
||||
|
||||
if (has-key $cmd-info[error] reason) {
|
||||
if (has-key $cmd-info[error][reason] exit-status) {
|
||||
set exit-status = $cmd-info[error][reason][exit-status]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
printf "\e]133;D;"$exit-status"\a"
|
||||
}
|
||||
|
||||
fn report-pwd {
|
||||
printf "\e]7;file://%s%s\a" (hostname) (pwd)
|
||||
}
|
||||
|
||||
fn sudo-with-terminfo {|@args|
|
||||
var sudoedit = $false
|
||||
for arg $args {
|
||||
use str
|
||||
if (str:has-prefix $arg -) {
|
||||
if (has-value [e -edit] $arg[1..]) {
|
||||
set sudoedit = $true
|
||||
break
|
||||
}
|
||||
continue
|
||||
}
|
||||
|
||||
if (not (has-value $arg =)) { break }
|
||||
}
|
||||
|
||||
if (not $sudoedit) { set args = [ TERMINFO=$E:TERMINFO $@args ] }
|
||||
command sudo $@args
|
||||
}
|
||||
|
||||
defer {
|
||||
mark-prompt-start
|
||||
report-pwd
|
||||
}
|
||||
|
||||
set edit:before-readline = (conj $edit:before-readline $mark-prompt-start~)
|
||||
set edit:after-readline = (conj $edit:after-readline $mark-output-start~)
|
||||
set edit:after-command = (conj $edit:after-command $mark-output-end~)
|
||||
|
||||
var no-title = (eq 1 $E:GHOSTTY_SHELL_INTEGRATION_NO_TITLE)
|
||||
var no-cursor = (eq 1 $E:GHOSTTY_SHELL_INTEGRATION_NO_CURSOR)
|
||||
var no-sudo = (eq 1 $E:GHOSTTY_SHELL_INTEGRATION_NO_SUDO)
|
||||
|
||||
if (not $no-title) {
|
||||
set after-chdir = (conj $after-chdir {|_| report-pwd })
|
||||
}
|
||||
if (not $no-cursor) {
|
||||
fn beam { printf "\e[5 q" }
|
||||
fn block { printf "\e[0 q" }
|
||||
set edit:before-readline = (conj $edit:before-readline $beam~)
|
||||
set edit:after-readline = (conj $edit:after-readline {|_| block })
|
||||
}
|
||||
if (and (not $no-sudo) (not-eq "" $E:TERMINFO) (eq file (type -t sudo))) {
|
||||
edit:add-var sudo~ $sudo-with-terminfo~
|
||||
}
|
||||
}
|
|
@ -0,0 +1,135 @@
|
|||
# This shell script aims to be written in a way where it can't really fail
|
||||
# or all failure scenarios are handled, so that we never leave the shell in
|
||||
# a weird state. If you find a way to break this, please report a bug!
|
||||
|
||||
function ghostty_restore_xdg_data_dir -d "restore the original XDG_DATA_DIR value"
|
||||
# If we don't have our own data dir then we don't need to do anything.
|
||||
if not set -q GHOSTTY_SHELL_INTEGRATION_XDG_DIR
|
||||
return
|
||||
end
|
||||
|
||||
# If the data dir isn't set at all then we don't need to do anything.
|
||||
if not set -q XDG_DATA_DIRS
|
||||
return
|
||||
end
|
||||
|
||||
# We need to do this so that XDG_DATA_DIRS turns into an array.
|
||||
set --function --path xdg_data_dirs "$XDG_DATA_DIRS"
|
||||
|
||||
# If our data dir is in the list then remove it.
|
||||
if set --function index (contains --index "$GHOSTTY_SHELL_INTEGRATION_XDG_DIR" $xdg_data_dirs)
|
||||
set --erase --function xdg_data_dirs[$index]
|
||||
end
|
||||
|
||||
# Re-export our data dir
|
||||
if set -q xdg_data_dirs[1]
|
||||
set --global --export --unpath XDG_DATA_DIRS "$xdg_data_dirs"
|
||||
else
|
||||
set --erase --global XDG_DATA_DIRS
|
||||
end
|
||||
|
||||
set --erase GHOSTTY_SHELL_INTEGRATION_XDG_DIR
|
||||
end
|
||||
|
||||
function ghostty_exit -d "exit the shell integration setup"
|
||||
functions -e ghostty_restore_xdg_data_dir
|
||||
functions -e ghostty_exit
|
||||
exit 0
|
||||
end
|
||||
|
||||
# We always try to restore the XDG data dir
|
||||
ghostty_restore_xdg_data_dir
|
||||
|
||||
# If we aren't interactive or we've already run, don't run.
|
||||
status --is-interactive || ghostty_exit
|
||||
|
||||
# We do the full setup on the first prompt render. We do this so that other
|
||||
# shell integrations that setup the prompt and modify things are able to run
|
||||
# first. We want to run _last_.
|
||||
function __ghostty_setup --on-event fish_prompt -d "Setup ghostty integration"
|
||||
functions -e __ghostty_setup
|
||||
|
||||
# Check if we are setting cursors
|
||||
set --local no_cursor "$GHOSTTY_SHELL_INTEGRATION_NO_CURSOR"
|
||||
|
||||
if test -z $no_cursor
|
||||
# Change the cursor to a beam on prompt.
|
||||
function __ghostty_set_cursor_beam --on-event fish_prompt -d "Set cursor shape"
|
||||
echo -en "\e[5 q"
|
||||
end
|
||||
function __ghostty_reset_cursor --on-event fish_preexec -d "Reset cursor shape"
|
||||
echo -en "\e[0 q"
|
||||
end
|
||||
end
|
||||
|
||||
# Check if we are setting sudo
|
||||
set --local no_sudo "$GHOSTTY_SHELL_INTEGRATION_NO_SUDO"
|
||||
|
||||
# When using sudo shell integration feature, ensure $TERMINFO is set
|
||||
# and `sudo` is not already a function or alias
|
||||
if test -z $no_sudo
|
||||
and test -n "$TERMINFO"; and test "file" = (type -t sudo 2> /dev/null; or echo "x")
|
||||
# Wrap `sudo` command to ensure Ghostty terminfo is preserved
|
||||
function sudo -d "Wrap sudo to preserve terminfo"
|
||||
set --local sudo_has_sudoedit_flags "no"
|
||||
for arg in $argv
|
||||
# Check if argument is '-e' or '--edit' (sudoedit flags)
|
||||
if string match -q -- "-e" "$arg"; or string match -q -- "--edit" "$arg"
|
||||
set --local sudo_has_sudoedit_flags "yes"
|
||||
break
|
||||
end
|
||||
# Check if argument is neither an option nor a key-value pair
|
||||
if not string match -r -q -- "^-" "$arg"; and not string match -r -q -- "=" "$arg"
|
||||
break
|
||||
end
|
||||
end
|
||||
if test "$sudo_has_sudoedit_flags" = "yes"
|
||||
command sudo $argv
|
||||
else
|
||||
command sudo TERMINFO="$TERMINFO" $argv
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
# Setup prompt marking
|
||||
function __ghostty_mark_prompt_start --on-event fish_prompt --on-event fish_cancel --on-event fish_posterror
|
||||
# If we never got the output end event, then we need to send it now.
|
||||
if test "$__ghostty_prompt_state" != prompt-start
|
||||
echo -en "\e]133;D\a"
|
||||
end
|
||||
|
||||
set --global __ghostty_prompt_state prompt-start
|
||||
echo -en "\e]133;A\a"
|
||||
end
|
||||
|
||||
function __ghostty_mark_output_start --on-event fish_preexec
|
||||
set --global __ghostty_prompt_state pre-exec
|
||||
echo -en "\e]133;C\a"
|
||||
end
|
||||
|
||||
function __ghostty_mark_output_end --on-event fish_postexec
|
||||
set --global __ghostty_prompt_state post-exec
|
||||
echo -en "\e]133;D;$status\a"
|
||||
end
|
||||
|
||||
# Report pwd. This is actually built-in to fish but only for terminals
|
||||
# that match an allowlist and that isn't us.
|
||||
function __update_cwd_osc --on-variable PWD -d 'Notify capable terminals when $PWD changes'
|
||||
if status --is-command-substitution || set -q INSIDE_EMACS
|
||||
return
|
||||
end
|
||||
printf \e\]7\;file://%s%s\a $hostname (string escape --style=url $PWD)
|
||||
end
|
||||
|
||||
# Enable fish to handle reflow because Ghostty clears the prompt on resize.
|
||||
set --global fish_handle_reflow 1
|
||||
|
||||
# Initial calls for first prompt
|
||||
if test -z $no_cursor
|
||||
__ghostty_set_cursor_beam
|
||||
end
|
||||
__ghostty_mark_prompt_start
|
||||
__update_cwd_osc
|
||||
end
|
||||
|
||||
ghostty_exit
|
60
bin/share/ghostty/shell-integration/zsh/.zshenv
Normal file
60
bin/share/ghostty/shell-integration/zsh/.zshenv
Normal file
|
@ -0,0 +1,60 @@
|
|||
# Based on (started as) a copy of Kitty's zsh integration. Kitty is
|
||||
# distributed under GPLv3, so this file is also distributed under GPLv3.
|
||||
# The license header is reproduced below:
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# This file can get sourced with aliases enabled. To avoid alias expansion
|
||||
# we quote everything that can be quoted. Some aliases will still break us
|
||||
# though.
|
||||
|
||||
# Restore the original ZDOTDIR value.
|
||||
if [[ -n "${GHOSTTY_ZSH_ZDOTDIR+X}" ]]; then
|
||||
'builtin' 'export' ZDOTDIR="$GHOSTTY_ZSH_ZDOTDIR"
|
||||
'builtin' 'unset' 'GHOSTTY_ZSH_ZDOTDIR'
|
||||
else
|
||||
'builtin' 'unset' 'ZDOTDIR'
|
||||
fi
|
||||
|
||||
# Use try-always to have the right error code.
|
||||
{
|
||||
# Zsh treats empty $ZDOTDIR as if it was "/". We do the same.
|
||||
#
|
||||
# Source the user's zshenv before sourcing ghostty.zsh because the former
|
||||
# might set fpath and other things without which ghostty.zsh won't work.
|
||||
#
|
||||
# Use typeset in case we are in a function with warn_create_global in
|
||||
# effect. Unlikely but better safe than sorry.
|
||||
'builtin' 'typeset' _ghostty_file=${ZDOTDIR-~}"/.zshenv"
|
||||
# Zsh ignores unreadable rc files. We do the same.
|
||||
# Zsh ignores rc files that are directories, and so does source.
|
||||
[[ ! -r "$_ghostty_file" ]] || 'builtin' 'source' '--' "$_ghostty_file"
|
||||
} always {
|
||||
if [[ -o 'interactive' ]]; then
|
||||
'builtin' 'autoload' '--' 'is-at-least'
|
||||
'is-at-least' "5.1" || {
|
||||
builtin echo "ZSH ${ZSH_VERSION} is too old for ghostty shell integration" > /dev/stderr
|
||||
return
|
||||
}
|
||||
# ${(%):-%x} is the path to the current file.
|
||||
# On top of it we add :A:h to get the directory.
|
||||
'builtin' 'typeset' _ghostty_file="${${(%):-%x}:A:h}"/ghostty-integration
|
||||
if [[ -r "$_ghostty_file" ]]; then
|
||||
'builtin' 'autoload' '-Uz' '--' "$_ghostty_file"
|
||||
"${_ghostty_file:t}"
|
||||
'builtin' 'unfunction' '--' "${_ghostty_file:t}"
|
||||
fi
|
||||
fi
|
||||
'builtin' 'unset' '_ghostty_file'
|
||||
}
|
316
bin/share/ghostty/shell-integration/zsh/ghostty-integration
Normal file
316
bin/share/ghostty/shell-integration/zsh/ghostty-integration
Normal file
|
@ -0,0 +1,316 @@
|
|||
# Based on (started as) a copy of Kitty's zsh integration. Kitty is
|
||||
# distributed under GPLv3, so this file is also distributed under GPLv3.
|
||||
# The license header is reproduced below:
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, either version 3 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
#
|
||||
# Enables integration between zsh and ghostty.
|
||||
#
|
||||
# This is an autoloadable function. It's invoked automatically in shells
|
||||
# directly spawned by Ghostty but not in any other shells. For example, running
|
||||
# `exec zsh`, `sudo -E zsh`, `tmux`, or plain `zsh` will create a shell where
|
||||
# ghostty-integration won't automatically run. Zsh users who want integration with
|
||||
# Ghostty in all shells should add the following lines to their .zshrc:
|
||||
#
|
||||
# if [[ -n $GHOSTTY_RESOURCES_DIR ]]; then
|
||||
# "$GHOSTTY_RESOURCES_DIR"/shell-integration/zsh/ghostty-integration
|
||||
# fi
|
||||
#
|
||||
# Implementation note: We can assume that alias expansion is disabled in this
|
||||
# file, so no need to quote defensively. We still have to defensively prefix all
|
||||
# builtins with `builtin` to avoid accidentally invoking user-defined functions.
|
||||
# We avoid `function` reserved word as an additional defensive measure.
|
||||
|
||||
# Note that updating options with `builtin emulate -L zsh` affects the global options
|
||||
# if it's called outside of a function. So nearly all code has to be in functions.
|
||||
_entrypoint() {
|
||||
builtin emulate -L zsh -o no_warn_create_global -o no_aliases
|
||||
|
||||
[[ -o interactive ]] || builtin return 0 # non-interactive shell
|
||||
(( ! $+_ghostty_state )) || builtin return 0 # already initialized
|
||||
|
||||
# 0: no OSC 133 [AC] marks have been written yet.
|
||||
# 1: the last written OSC 133 C has not been closed with D yet.
|
||||
# 2: none of the above.
|
||||
builtin typeset -gi _ghostty_state
|
||||
|
||||
# Attempt to create a writable file descriptor to the TTY so that we can print
|
||||
# to the TTY later even when STDOUT is redirected. This code is fairly subtle.
|
||||
#
|
||||
# - It's tempting to do `[[ -t 1 ]] && exec {_ghostty_state}>&1` but we cannot do this
|
||||
# because it'll create a file descriptor >= 10 without O_CLOEXEC. This file
|
||||
# descriptor will leak to child processes.
|
||||
# - If we do `exec {3}>&1`, the file descriptor won't leak to the child processes
|
||||
# but it'll still leak if the current process is replaced with another. In
|
||||
# addition, it'll break user code that relies on fd 3 being available.
|
||||
# - Zsh doesn't expose dup3, which would have allowed us to copy STDOUT with
|
||||
# O_CLOEXEC. The only way to create a file descriptor with O_CLOEXEC is via
|
||||
# sysopen.
|
||||
# - `zmodload zsh/system` and `sysopen -o cloexec -wu _ghostty_fd -- /dev/tty` can
|
||||
# fail with an error message to STDERR (the latter can happen even if /dev/tty
|
||||
# is writable), hence the redirection of STDERR. We do it for the whole block
|
||||
# for performance reasons (redirections are slow).
|
||||
# - We must open the file descriptor right here rather than in _ghostty_deferred_init
|
||||
# because there are broken zsh plugins out there that run `exec {fd}< <(cmd)`
|
||||
# and then close the file descriptor more than once while suppressing errors.
|
||||
# This could end up closing our file descriptor if we opened it in
|
||||
# _ghostty_deferred_init.
|
||||
typeset -gi _ghostty_fd
|
||||
{
|
||||
builtin zmodload zsh/system && (( $+builtins[sysopen] )) && {
|
||||
{ [[ -w $TTY ]] && builtin sysopen -o cloexec -wu _ghostty_fd -- $TTY } ||
|
||||
{ [[ -w /dev/tty ]] && builtin sysopen -o cloexec -wu _ghostty_fd -- /dev/tty }
|
||||
}
|
||||
} 2>/dev/null || (( _ghostty_fd = 1 ))
|
||||
|
||||
# Defer initialization so that other zsh init files can be configure
|
||||
# the integration.
|
||||
builtin typeset -ag precmd_functions
|
||||
precmd_functions+=(_ghostty_deferred_init)
|
||||
}
|
||||
|
||||
_ghostty_deferred_init() {
|
||||
builtin emulate -L zsh -o no_warn_create_global -o no_aliases
|
||||
|
||||
# The directory where ghostty-integration is located: /../shell-integration/zsh.
|
||||
builtin local self_dir="${functions_source[_ghostty_deferred_init]:A:h}"
|
||||
|
||||
# Enable semantic markup with OSC 133.
|
||||
_ghostty_precmd() {
|
||||
builtin local -i cmd_status=$?
|
||||
builtin emulate -L zsh -o no_warn_create_global -o no_aliases
|
||||
|
||||
# Don't write OSC 133 D when our precmd handler is invoked from zle.
|
||||
# Some plugins do that to update prompt on cd.
|
||||
if ! builtin zle; then
|
||||
# This code works incorrectly in the presence of a precmd or chpwd
|
||||
# hook that prints. For example, sindresorhus/pure prints an empty
|
||||
# line on precmd and marlonrichert/zsh-snap prints $PWD on chpwd.
|
||||
# We'll end up writing our OSC 133 D mark too late.
|
||||
#
|
||||
# Another failure mode is when the output of a command doesn't end
|
||||
# with LF and prompst_sp is set (it is by default). In this case
|
||||
# we'll incorrectly state that '%' from prompt_sp is a part of the
|
||||
# command's output.
|
||||
if (( _ghostty_state == 1 )); then
|
||||
# The last written OSC 133 C has not been closed with D yet.
|
||||
# Close it and supply status.
|
||||
builtin print -nu $_ghostty_fd '\e]133;D;'$cmd_status'\a'
|
||||
(( _ghostty_state = 2 ))
|
||||
elif (( _ghostty_state == 2 )); then
|
||||
# There might be an unclosed OSC 133 C. Close that.
|
||||
builtin print -nu $_ghostty_fd '\e]133;D\a'
|
||||
fi
|
||||
fi
|
||||
|
||||
builtin local mark1=$'%{\e]133;A\a%}'
|
||||
if [[ -o prompt_percent ]]; then
|
||||
builtin typeset -g precmd_functions
|
||||
if [[ ${precmd_functions[-1]} == _ghostty_precmd ]]; then
|
||||
# This is the best case for us: we can add our marks to PS1 and
|
||||
# PS2. This way our marks will be printed whenever zsh
|
||||
# redisplays prompt: on reset-prompt, on SIGWINCH, and on
|
||||
# SIGCHLD if notify is set. Themes that update prompt
|
||||
# asynchronously from a `zle -F` handler might still remove our
|
||||
# marks. Oh well.
|
||||
builtin local mark2=$'%{\e]133;A;k=s\a%}'
|
||||
# Add marks conditionally to avoid a situation where we have
|
||||
# several marks in place. These conditions can have false
|
||||
# positives and false negatives though.
|
||||
#
|
||||
# - False positive (with prompt_percent): PS1="%(?.$mark1.)"
|
||||
# - False negative (with prompt_subst): PS1='$mark1'
|
||||
[[ $PS1 == *$mark1* ]] || PS1=${mark1}${PS1}
|
||||
# PS2 mark is needed when clearing the prompt on resize
|
||||
[[ $PS2 == *$mark2* ]] || PS2=${mark2}${PS2}
|
||||
(( _ghostty_state = 2 ))
|
||||
else
|
||||
# If our precmd hook is not the last, we cannot rely on prompt
|
||||
# changes to stick, so we don't even try. At least we can move
|
||||
# our hook to the end to have better luck next time. If there is
|
||||
# another piece of code that wants to take this privileged
|
||||
# position, this won't work well. We'll break them as much as
|
||||
# they are breaking us.
|
||||
precmd_functions=(${precmd_functions:#_ghostty_precmd} _ghostty_precmd)
|
||||
# Plugins that invoke precmd hooks from zle do that before zle
|
||||
# is trashed. This means that the cursor is in the middle of
|
||||
# BUFFER and we cannot print our mark there. Prompt might
|
||||
# already have a mark, so the following reset-prompt will write
|
||||
# it. If it doesn't, there is nothing we can do.
|
||||
if ! builtin zle; then
|
||||
builtin print -rnu $_ghostty_fd -- $mark1[3,-3]
|
||||
(( _ghostty_state = 2 ))
|
||||
fi
|
||||
fi
|
||||
elif ! builtin zle; then
|
||||
# Without prompt_percent we cannot patch prompt. Just print the
|
||||
# mark, except when we are invoked from zle. In the latter case we
|
||||
# cannot do anything.
|
||||
builtin print -rnu $_ghostty_fd -- $mark1[3,-3]
|
||||
(( _ghostty_state = 2 ))
|
||||
fi
|
||||
}
|
||||
|
||||
_ghostty_preexec() {
|
||||
builtin emulate -L zsh -o no_warn_create_global -o no_aliases
|
||||
|
||||
# This can potentially break user prompt. Oh well. The robustness of
|
||||
# this code can be improved in the case prompt_subst is set because
|
||||
# it'll allow us distinguish (not perfectly but close enough) between
|
||||
# our own prompt, user prompt, and our own prompt with user additions on
|
||||
# top. We cannot force prompt_subst on the user though, so we would
|
||||
# still need this code for the no_prompt_subst case.
|
||||
PS1=${PS1//$'%{\e]133;A\a%}'}
|
||||
PS2=${PS2//$'%{\e]133;A;k=s\a%}'}
|
||||
|
||||
# This will work incorrectly in the presence of a preexec hook that
|
||||
# prints. For example, if MichaelAquilina/zsh-you-should-use installs
|
||||
# its preexec hook before us, we'll incorrectly mark its output as
|
||||
# belonging to the command (as if the user typed it into zle) rather
|
||||
# than command output.
|
||||
builtin print -nu $_ghostty_fd '\e]133;C\a'
|
||||
(( _ghostty_state = 1 ))
|
||||
}
|
||||
|
||||
# Enable reporting current working dir to terminal. Ghostty supports
|
||||
# the kitty-shell-cwd format.
|
||||
_ghostty_report_pwd() { builtin print -nu $_ghostty_fd '\e]7;kitty-shell-cwd://'"$HOST""$PWD"'\a'; }
|
||||
chpwd_functions=(${chpwd_functions[@]} "_ghostty_report_pwd")
|
||||
# An executed program could change cwd and report the changed cwd, so also report cwd at each new prompt
|
||||
# as in this case chpwd_functions is insufficient. chpwd_functions is still needed for things like: cd x && something
|
||||
functions[_ghostty_precmd]+="
|
||||
_ghostty_report_pwd"
|
||||
_ghostty_report_pwd
|
||||
|
||||
if [[ "$GHOSTTY_SHELL_INTEGRATION_NO_TITLE" != 1 ]]; then
|
||||
# Enable terminal title changes.
|
||||
functions[_ghostty_precmd]+="
|
||||
builtin print -rnu $_ghostty_fd \$'\\e]2;'\"\${(%):-%(4~|…/%3~|%~)}\"\$'\\a'"
|
||||
functions[_ghostty_preexec]+="
|
||||
builtin print -rnu $_ghostty_fd \$'\\e]2;'\"\${(V)1}\"\$'\\a'"
|
||||
fi
|
||||
|
||||
if [[ "$GHOSTTY_SHELL_INTEGRATION_NO_CURSOR" != 1 ]]; then
|
||||
# Enable cursor shape changes depending on the current keymap.
|
||||
# This implementation leaks blinking block cursor into external commands
|
||||
# executed from zle. For example, users of fzf-based widgets may find
|
||||
# themselves with a blinking block cursor within fzf.
|
||||
_ghostty_zle_line_init _ghostty_zle_line_finish _ghostty_zle_keymap_select() {
|
||||
case ${KEYMAP-} in
|
||||
# Blinking block cursor.
|
||||
vicmd|visual) builtin print -nu "$_ghostty_fd" '\e[1 q';;
|
||||
# Blinking bar cursor.
|
||||
*) builtin print -nu "$_ghostty_fd" '\e[5 q';;
|
||||
esac
|
||||
}
|
||||
# Restore the blinking default shape before executing an external command
|
||||
functions[_ghostty_preexec]+="
|
||||
builtin print -rnu $_ghostty_fd \$'\\e[0 q'"
|
||||
fi
|
||||
|
||||
# Sudo
|
||||
if [[ "$GHOSTTY_SHELL_INTEGRATION_NO_SUDO" != "1" ]] && [[ -n "$TERMINFO" ]]; then
|
||||
# Wrap `sudo` command to ensure Ghostty terminfo is preserved
|
||||
sudo() {
|
||||
builtin local sudo_has_sudoedit_flags="no"
|
||||
for arg in "$@"; do
|
||||
# Check if argument is '-e' or '--edit' (sudoedit flags)
|
||||
if [[ "$arg" == "-e" || $arg == "--edit" ]]; then
|
||||
sudo_has_sudoedit_flags="yes"
|
||||
builtin break
|
||||
fi
|
||||
# Check if argument is neither an option nor a key-value pair
|
||||
if [[ "$arg" != -* && "$arg" != *=* ]]; then
|
||||
builtin break
|
||||
fi
|
||||
done
|
||||
if [[ "$sudo_has_sudoedit_flags" == "yes" ]]; then
|
||||
builtin command sudo "$@";
|
||||
else
|
||||
builtin command sudo TERMINFO="$TERMINFO" "$@";
|
||||
fi
|
||||
}
|
||||
fi
|
||||
|
||||
# Some zsh users manually run `source ~/.zshrc` in order to apply rc file
|
||||
# changes to the current shell. This is a terrible practice that breaks many
|
||||
# things, including our shell integration. For example, Oh My Zsh and Prezto
|
||||
# (both very popular among zsh users) will remove zle-line-init and
|
||||
# zle-line-finish hooks if .zshrc is manually sourced. Prezto will also remove
|
||||
# zle-keymap-select.
|
||||
#
|
||||
# Another common (and much more robust) way to apply rc file changes to the
|
||||
# current shell is `exec zsh`. This will remove our integration from the shell
|
||||
# unless it's explicitly invoked from .zshrc. This is not an issue with
|
||||
# `exec zsh` but rather with our implementation of automatic shell integration.
|
||||
|
||||
# In the ideal world we would use add-zle-hook-widget to hook zle-line-init
|
||||
# and similar widget. This breaks user configs though, so we have do this
|
||||
# horrible thing instead.
|
||||
builtin local hook func widget orig_widget flag
|
||||
for hook in line-init line-finish keymap-select; do
|
||||
func=_ghostty_zle_${hook/-/_}
|
||||
(( $+functions[$func] )) || builtin continue
|
||||
widget=zle-$hook
|
||||
if [[ $widgets[$widget] == user:azhw:* &&
|
||||
$+functions[add-zle-hook-widget] -eq 1 ]]; then
|
||||
# If the widget is already hooked by add-zle-hook-widget at the top
|
||||
# level, add our hook at the end. We MUST do it this way. We cannot
|
||||
# just wrap the widget ourselves in this case because it would
|
||||
# trigger bugs in add-zle-hook-widget.
|
||||
add-zle-hook-widget $hook $func
|
||||
else
|
||||
if (( $+widgets[$widget] )); then
|
||||
# There is a widget but it's not from add-zle-hook-widget. We
|
||||
# can rename the original widget, install our own and invoke
|
||||
# the original when we are called.
|
||||
#
|
||||
# Note: The leading dot is to work around bugs in
|
||||
# zsh-syntax-highlighting.
|
||||
orig_widget=._ghostty_orig_$widget
|
||||
builtin zle -A $widget $orig_widget
|
||||
if [[ $widgets[$widget] == user:* ]]; then
|
||||
# No -w here to preserve $WIDGET within the original widget.
|
||||
flag=
|
||||
else
|
||||
flag=w
|
||||
fi
|
||||
functions[$func]+="
|
||||
builtin zle $orig_widget -N$flag -- \"\$@\""
|
||||
fi
|
||||
builtin zle -N $widget $func
|
||||
fi
|
||||
done
|
||||
|
||||
if (( $+functions[_ghostty_preexec] )); then
|
||||
builtin typeset -ag preexec_functions
|
||||
preexec_functions+=(_ghostty_preexec)
|
||||
fi
|
||||
|
||||
builtin typeset -ag precmd_functions
|
||||
if (( $+functions[_ghostty_precmd] )); then
|
||||
precmd_functions=(${precmd_functions:/_ghostty_deferred_init/_ghostty_precmd})
|
||||
_ghostty_precmd
|
||||
else
|
||||
precmd_functions=(${precmd_functions:#_ghostty_deferred_init})
|
||||
fi
|
||||
|
||||
# Unfunction _ghostty_deferred_init to save memory. Don't unfunction
|
||||
# ghostty-integration though because decent public functions aren't supposed to
|
||||
# to unfunction themselves when invoked. Unfunctioning is done by calling code.
|
||||
builtin unfunction _ghostty_deferred_init
|
||||
}
|
||||
|
||||
_entrypoint
|
21
bin/share/ghostty/themes/3024 Day
Normal file
21
bin/share/ghostty/themes/3024 Day
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#090300
|
||||
palette = 1=#db2d20
|
||||
palette = 2=#01a252
|
||||
palette = 3=#fded02
|
||||
palette = 4=#01a0e4
|
||||
palette = 5=#a16a94
|
||||
palette = 6=#b5e4f4
|
||||
palette = 7=#a5a2a2
|
||||
palette = 8=#5c5855
|
||||
palette = 9=#e8bbd0
|
||||
palette = 10=#3a3432
|
||||
palette = 11=#4a4543
|
||||
palette = 12=#807d7c
|
||||
palette = 13=#d6d5d4
|
||||
palette = 14=#cdab53
|
||||
palette = 15=#f7f7f7
|
||||
background = f7f7f7
|
||||
foreground = 4a4543
|
||||
cursor-color = 4a4543
|
||||
selection-background = a5a2a2
|
||||
selection-foreground = 4a4543
|
21
bin/share/ghostty/themes/3024 Night
Normal file
21
bin/share/ghostty/themes/3024 Night
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#090300
|
||||
palette = 1=#db2d20
|
||||
palette = 2=#01a252
|
||||
palette = 3=#fded02
|
||||
palette = 4=#01a0e4
|
||||
palette = 5=#a16a94
|
||||
palette = 6=#b5e4f4
|
||||
palette = 7=#a5a2a2
|
||||
palette = 8=#5c5855
|
||||
palette = 9=#e8bbd0
|
||||
palette = 10=#3a3432
|
||||
palette = 11=#4a4543
|
||||
palette = 12=#807d7c
|
||||
palette = 13=#d6d5d4
|
||||
palette = 14=#cdab53
|
||||
palette = 15=#f7f7f7
|
||||
background = 090300
|
||||
foreground = a5a2a2
|
||||
cursor-color = a5a2a2
|
||||
selection-background = 4a4543
|
||||
selection-foreground = a5a2a2
|
21
bin/share/ghostty/themes/Aardvark Blue
Normal file
21
bin/share/ghostty/themes/Aardvark Blue
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#191919
|
||||
palette = 1=#aa342e
|
||||
palette = 2=#4b8c0f
|
||||
palette = 3=#dbba00
|
||||
palette = 4=#1370d3
|
||||
palette = 5=#c43ac3
|
||||
palette = 6=#008eb0
|
||||
palette = 7=#bebebe
|
||||
palette = 8=#454545
|
||||
palette = 9=#f05b50
|
||||
palette = 10=#95dc55
|
||||
palette = 11=#ffe763
|
||||
palette = 12=#60a4ec
|
||||
palette = 13=#e26be2
|
||||
palette = 14=#60b6cb
|
||||
palette = 15=#f7f7f7
|
||||
background = 102040
|
||||
foreground = dddddd
|
||||
cursor-color = 007acc
|
||||
selection-background = bfdbfe
|
||||
selection-foreground = 000000
|
21
bin/share/ghostty/themes/Abernathy
Normal file
21
bin/share/ghostty/themes/Abernathy
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#cd0000
|
||||
palette = 2=#00cd00
|
||||
palette = 3=#cdcd00
|
||||
palette = 4=#1093f5
|
||||
palette = 5=#cd00cd
|
||||
palette = 6=#00cdcd
|
||||
palette = 7=#faebd7
|
||||
palette = 8=#404040
|
||||
palette = 9=#ff0000
|
||||
palette = 10=#00ff00
|
||||
palette = 11=#ffff00
|
||||
palette = 12=#11b5f6
|
||||
palette = 13=#ff00ff
|
||||
palette = 14=#00ffff
|
||||
palette = 15=#ffffff
|
||||
background = 111416
|
||||
foreground = eeeeec
|
||||
cursor-color = bbbbbb
|
||||
selection-background = eeeeec
|
||||
selection-foreground = 333333
|
21
bin/share/ghostty/themes/Adventure
Normal file
21
bin/share/ghostty/themes/Adventure
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#040404
|
||||
palette = 1=#d84a33
|
||||
palette = 2=#5da602
|
||||
palette = 3=#eebb6e
|
||||
palette = 4=#417ab3
|
||||
palette = 5=#e5c499
|
||||
palette = 6=#bdcfe5
|
||||
palette = 7=#dbded8
|
||||
palette = 8=#685656
|
||||
palette = 9=#d76b42
|
||||
palette = 10=#99b52c
|
||||
palette = 11=#ffb670
|
||||
palette = 12=#97d7ef
|
||||
palette = 13=#aa7900
|
||||
palette = 14=#bdcfe5
|
||||
palette = 15=#e4d5c7
|
||||
background = 040404
|
||||
foreground = feffff
|
||||
cursor-color = feffff
|
||||
selection-background = 606060
|
||||
selection-foreground = ffffff
|
21
bin/share/ghostty/themes/AdventureTime
Normal file
21
bin/share/ghostty/themes/AdventureTime
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#050404
|
||||
palette = 1=#bd0013
|
||||
palette = 2=#4ab118
|
||||
palette = 3=#e7741e
|
||||
palette = 4=#0f4ac6
|
||||
palette = 5=#665993
|
||||
palette = 6=#70a598
|
||||
palette = 7=#f8dcc0
|
||||
palette = 8=#4e7cbf
|
||||
palette = 9=#fc5f5a
|
||||
palette = 10=#9eff6e
|
||||
palette = 11=#efc11a
|
||||
palette = 12=#1997c6
|
||||
palette = 13=#9b5953
|
||||
palette = 14=#c8faf4
|
||||
palette = 15=#f6f5fb
|
||||
background = 1f1d45
|
||||
foreground = f8dcc0
|
||||
cursor-color = efbf38
|
||||
selection-background = 706b4e
|
||||
selection-foreground = f3d9c4
|
21
bin/share/ghostty/themes/Afterglow
Normal file
21
bin/share/ghostty/themes/Afterglow
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#151515
|
||||
palette = 1=#ac4142
|
||||
palette = 2=#7e8e50
|
||||
palette = 3=#e5b567
|
||||
palette = 4=#6c99bb
|
||||
palette = 5=#9f4e85
|
||||
palette = 6=#7dd6cf
|
||||
palette = 7=#d0d0d0
|
||||
palette = 8=#505050
|
||||
palette = 9=#ac4142
|
||||
palette = 10=#7e8e50
|
||||
palette = 11=#e5b567
|
||||
palette = 12=#6c99bb
|
||||
palette = 13=#9f4e85
|
||||
palette = 14=#7dd6cf
|
||||
palette = 15=#f5f5f5
|
||||
background = 212121
|
||||
foreground = d0d0d0
|
||||
cursor-color = d0d0d0
|
||||
selection-background = 303030
|
||||
selection-foreground = d0d0d0
|
21
bin/share/ghostty/themes/Alabaster
Normal file
21
bin/share/ghostty/themes/Alabaster
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#aa3731
|
||||
palette = 2=#448c27
|
||||
palette = 3=#cb9000
|
||||
palette = 4=#325cc0
|
||||
palette = 5=#7a3e9d
|
||||
palette = 6=#0083b2
|
||||
palette = 7=#f7f7f7
|
||||
palette = 8=#777777
|
||||
palette = 9=#f05050
|
||||
palette = 10=#60cb00
|
||||
palette = 11=#ffbc5d
|
||||
palette = 12=#007acc
|
||||
palette = 13=#e64ce6
|
||||
palette = 14=#00aacb
|
||||
palette = 15=#f7f7f7
|
||||
background = f7f7f7
|
||||
foreground = 000000
|
||||
cursor-color = 007acc
|
||||
selection-background = bfdbfe
|
||||
selection-foreground = 000000
|
21
bin/share/ghostty/themes/AlienBlood
Normal file
21
bin/share/ghostty/themes/AlienBlood
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#112616
|
||||
palette = 1=#7f2b27
|
||||
palette = 2=#2f7e25
|
||||
palette = 3=#717f24
|
||||
palette = 4=#2f6a7f
|
||||
palette = 5=#47587f
|
||||
palette = 6=#327f77
|
||||
palette = 7=#647d75
|
||||
palette = 8=#3c4812
|
||||
palette = 9=#e08009
|
||||
palette = 10=#18e000
|
||||
palette = 11=#bde000
|
||||
palette = 12=#00aae0
|
||||
palette = 13=#0058e0
|
||||
palette = 14=#00e0c4
|
||||
palette = 15=#73fa91
|
||||
background = 0f1610
|
||||
foreground = 637d75
|
||||
cursor-color = 73fa91
|
||||
selection-background = 1d4125
|
||||
selection-foreground = 73fa91
|
21
bin/share/ghostty/themes/Andromeda
Normal file
21
bin/share/ghostty/themes/Andromeda
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#cd3131
|
||||
palette = 2=#05bc79
|
||||
palette = 3=#e5e512
|
||||
palette = 4=#2472c8
|
||||
palette = 5=#bc3fbc
|
||||
palette = 6=#0fa8cd
|
||||
palette = 7=#e5e5e5
|
||||
palette = 8=#666666
|
||||
palette = 9=#cd3131
|
||||
palette = 10=#05bc79
|
||||
palette = 11=#e5e512
|
||||
palette = 12=#2472c8
|
||||
palette = 13=#bc3fbc
|
||||
palette = 14=#0fa8cd
|
||||
palette = 15=#e5e5e5
|
||||
background = 262a33
|
||||
foreground = e5e5e5
|
||||
cursor-color = f8f8f0
|
||||
selection-background = 5a5c62
|
||||
selection-foreground = ece7e7
|
21
bin/share/ghostty/themes/Apple Classic
Normal file
21
bin/share/ghostty/themes/Apple Classic
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#c91b00
|
||||
palette = 2=#00c200
|
||||
palette = 3=#c7c400
|
||||
palette = 4=#0225c7
|
||||
palette = 5=#ca30c7
|
||||
palette = 6=#00c5c7
|
||||
palette = 7=#c7c7c7
|
||||
palette = 8=#686868
|
||||
palette = 9=#ff6e67
|
||||
palette = 10=#5ffa68
|
||||
palette = 11=#fffc67
|
||||
palette = 12=#6871ff
|
||||
palette = 13=#ff77ff
|
||||
palette = 14=#60fdff
|
||||
palette = 15=#ffffff
|
||||
background = 2c2b2b
|
||||
foreground = d5a200
|
||||
cursor-color = c7c7c7
|
||||
selection-background = 6b5b02
|
||||
selection-foreground = 67e000
|
21
bin/share/ghostty/themes/Apple System Colors
Normal file
21
bin/share/ghostty/themes/Apple System Colors
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#1a1a1a
|
||||
palette = 1=#cc372e
|
||||
palette = 2=#26a439
|
||||
palette = 3=#cdac08
|
||||
palette = 4=#0869cb
|
||||
palette = 5=#9647bf
|
||||
palette = 6=#479ec2
|
||||
palette = 7=#98989d
|
||||
palette = 8=#464646
|
||||
palette = 9=#ff453a
|
||||
palette = 10=#32d74b
|
||||
palette = 11=#ffd60a
|
||||
palette = 12=#0a84ff
|
||||
palette = 13=#bf5af2
|
||||
palette = 14=#76d6ff
|
||||
palette = 15=#ffffff
|
||||
background = 1e1e1e
|
||||
foreground = ffffff
|
||||
cursor-color = 98989d
|
||||
selection-background = 3f638b
|
||||
selection-foreground = ffffff
|
21
bin/share/ghostty/themes/Argonaut
Normal file
21
bin/share/ghostty/themes/Argonaut
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#232323
|
||||
palette = 1=#ff000f
|
||||
palette = 2=#8ce10b
|
||||
palette = 3=#ffb900
|
||||
palette = 4=#008df8
|
||||
palette = 5=#6d43a6
|
||||
palette = 6=#00d8eb
|
||||
palette = 7=#ffffff
|
||||
palette = 8=#444444
|
||||
palette = 9=#ff2740
|
||||
palette = 10=#abe15b
|
||||
palette = 11=#ffd242
|
||||
palette = 12=#0092ff
|
||||
palette = 13=#9a5feb
|
||||
palette = 14=#67fff0
|
||||
palette = 15=#ffffff
|
||||
background = 0e1019
|
||||
foreground = fffaf4
|
||||
cursor-color = ff0018
|
||||
selection-background = 002a3b
|
||||
selection-foreground = ffffff
|
21
bin/share/ghostty/themes/Arthur
Normal file
21
bin/share/ghostty/themes/Arthur
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#3d352a
|
||||
palette = 1=#cd5c5c
|
||||
palette = 2=#86af80
|
||||
palette = 3=#e8ae5b
|
||||
palette = 4=#6495ed
|
||||
palette = 5=#deb887
|
||||
palette = 6=#b0c4de
|
||||
palette = 7=#bbaa99
|
||||
palette = 8=#554444
|
||||
palette = 9=#cc5533
|
||||
palette = 10=#88aa22
|
||||
palette = 11=#ffa75d
|
||||
palette = 12=#87ceeb
|
||||
palette = 13=#996600
|
||||
palette = 14=#b0c4de
|
||||
palette = 15=#ddccbb
|
||||
background = 1c1c1c
|
||||
foreground = ddeedd
|
||||
cursor-color = e2bbef
|
||||
selection-background = 4d4d4d
|
||||
selection-foreground = ffffff
|
21
bin/share/ghostty/themes/AtelierSulphurpool
Normal file
21
bin/share/ghostty/themes/AtelierSulphurpool
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#202746
|
||||
palette = 1=#c94922
|
||||
palette = 2=#ac9739
|
||||
palette = 3=#c08b30
|
||||
palette = 4=#3d8fd1
|
||||
palette = 5=#6679cc
|
||||
palette = 6=#22a2c9
|
||||
palette = 7=#979db4
|
||||
palette = 8=#6b7394
|
||||
palette = 9=#c76b29
|
||||
palette = 10=#293256
|
||||
palette = 11=#5e6687
|
||||
palette = 12=#898ea4
|
||||
palette = 13=#dfe2f1
|
||||
palette = 14=#9c637a
|
||||
palette = 15=#f5f7ff
|
||||
background = 202746
|
||||
foreground = 979db4
|
||||
cursor-color = 979db4
|
||||
selection-background = 5e6687
|
||||
selection-foreground = 979db4
|
21
bin/share/ghostty/themes/Atom
Normal file
21
bin/share/ghostty/themes/Atom
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#fd5ff1
|
||||
palette = 2=#87c38a
|
||||
palette = 3=#ffd7b1
|
||||
palette = 4=#85befd
|
||||
palette = 5=#b9b6fc
|
||||
palette = 6=#85befd
|
||||
palette = 7=#e0e0e0
|
||||
palette = 8=#000000
|
||||
palette = 9=#fd5ff1
|
||||
palette = 10=#94fa36
|
||||
palette = 11=#f5ffa8
|
||||
palette = 12=#96cbfe
|
||||
palette = 13=#b9b6fc
|
||||
palette = 14=#85befd
|
||||
palette = 15=#e0e0e0
|
||||
background = 161719
|
||||
foreground = c5c8c6
|
||||
cursor-color = d0d0d0
|
||||
selection-background = 444444
|
||||
selection-foreground = c5c8c6
|
21
bin/share/ghostty/themes/AtomOneLight
Normal file
21
bin/share/ghostty/themes/AtomOneLight
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#de3e35
|
||||
palette = 2=#3f953a
|
||||
palette = 3=#d2b67c
|
||||
palette = 4=#2f5af3
|
||||
palette = 5=#950095
|
||||
palette = 6=#3f953a
|
||||
palette = 7=#bbbbbb
|
||||
palette = 8=#000000
|
||||
palette = 9=#de3e35
|
||||
palette = 10=#3f953a
|
||||
palette = 11=#d2b67c
|
||||
palette = 12=#2f5af3
|
||||
palette = 13=#a00095
|
||||
palette = 14=#3f953a
|
||||
palette = 15=#ffffff
|
||||
background = f9f9f9
|
||||
foreground = 2a2c33
|
||||
cursor-color = bbbbbb
|
||||
selection-background = ededed
|
||||
selection-foreground = 2a2c33
|
21
bin/share/ghostty/themes/Aurora
Normal file
21
bin/share/ghostty/themes/Aurora
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#23262e
|
||||
palette = 1=#f0266f
|
||||
palette = 2=#8fd46d
|
||||
palette = 3=#ffe66d
|
||||
palette = 4=#0321d7
|
||||
palette = 5=#ee5d43
|
||||
palette = 6=#03d6b8
|
||||
palette = 7=#c74ded
|
||||
palette = 8=#292e38
|
||||
palette = 9=#f92672
|
||||
palette = 10=#8fd46d
|
||||
palette = 11=#ffe66d
|
||||
palette = 12=#03d6b8
|
||||
palette = 13=#ee5d43
|
||||
palette = 14=#03d6b8
|
||||
palette = 15=#c74ded
|
||||
background = 23262e
|
||||
foreground = ffca28
|
||||
cursor-color = ee5d43
|
||||
selection-background = 292e38
|
||||
selection-foreground = 00e8c6
|
21
bin/share/ghostty/themes/Ayu Mirage
Normal file
21
bin/share/ghostty/themes/Ayu Mirage
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#191e2a
|
||||
palette = 1=#ed8274
|
||||
palette = 2=#a6cc70
|
||||
palette = 3=#fad07b
|
||||
palette = 4=#6dcbfa
|
||||
palette = 5=#cfbafa
|
||||
palette = 6=#90e1c6
|
||||
palette = 7=#c7c7c7
|
||||
palette = 8=#686868
|
||||
palette = 9=#f28779
|
||||
palette = 10=#bae67e
|
||||
palette = 11=#ffd580
|
||||
palette = 12=#73d0ff
|
||||
palette = 13=#d4bfff
|
||||
palette = 14=#95e6cb
|
||||
palette = 15=#ffffff
|
||||
background = 1f2430
|
||||
foreground = cbccc6
|
||||
cursor-color = ffcc66
|
||||
selection-background = 33415e
|
||||
selection-foreground = cbccc6
|
21
bin/share/ghostty/themes/Banana Blueberry
Normal file
21
bin/share/ghostty/themes/Banana Blueberry
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#17141f
|
||||
palette = 1=#ff6b7f
|
||||
palette = 2=#00bd9c
|
||||
palette = 3=#e6c62f
|
||||
palette = 4=#22e8df
|
||||
palette = 5=#dc396a
|
||||
palette = 6=#56b6c2
|
||||
palette = 7=#f1f1f1
|
||||
palette = 8=#495162
|
||||
palette = 9=#fe9ea1
|
||||
palette = 10=#98c379
|
||||
palette = 11=#f9e46b
|
||||
palette = 12=#91fff4
|
||||
palette = 13=#da70d6
|
||||
palette = 14=#bcf3ff
|
||||
palette = 15=#ffffff
|
||||
background = 191323
|
||||
foreground = cccccc
|
||||
cursor-color = e07d13
|
||||
selection-background = 220525
|
||||
selection-foreground = f4f4f4
|
21
bin/share/ghostty/themes/Batman
Normal file
21
bin/share/ghostty/themes/Batman
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#1b1d1e
|
||||
palette = 1=#e6dc44
|
||||
palette = 2=#c8be46
|
||||
palette = 3=#f4fd22
|
||||
palette = 4=#737174
|
||||
palette = 5=#747271
|
||||
palette = 6=#62605f
|
||||
palette = 7=#c6c5bf
|
||||
palette = 8=#505354
|
||||
palette = 9=#fff78e
|
||||
palette = 10=#fff27d
|
||||
palette = 11=#feed6c
|
||||
palette = 12=#919495
|
||||
palette = 13=#9a9a9d
|
||||
palette = 14=#a3a3a6
|
||||
palette = 15=#dadbd6
|
||||
background = 1b1d1e
|
||||
foreground = 6f6f6f
|
||||
cursor-color = fcef0c
|
||||
selection-background = 4d504c
|
||||
selection-foreground = f0e04a
|
21
bin/share/ghostty/themes/Belafonte Day
Normal file
21
bin/share/ghostty/themes/Belafonte Day
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#20111b
|
||||
palette = 1=#be100e
|
||||
palette = 2=#858162
|
||||
palette = 3=#eaa549
|
||||
palette = 4=#426a79
|
||||
palette = 5=#97522c
|
||||
palette = 6=#989a9c
|
||||
palette = 7=#968c83
|
||||
palette = 8=#5e5252
|
||||
palette = 9=#be100e
|
||||
palette = 10=#858162
|
||||
palette = 11=#eaa549
|
||||
palette = 12=#426a79
|
||||
palette = 13=#97522c
|
||||
palette = 14=#989a9c
|
||||
palette = 15=#d5ccba
|
||||
background = d5ccba
|
||||
foreground = 45373c
|
||||
cursor-color = 45373c
|
||||
selection-background = 968c83
|
||||
selection-foreground = 45373c
|
21
bin/share/ghostty/themes/Belafonte Night
Normal file
21
bin/share/ghostty/themes/Belafonte Night
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#20111b
|
||||
palette = 1=#be100e
|
||||
palette = 2=#858162
|
||||
palette = 3=#eaa549
|
||||
palette = 4=#426a79
|
||||
palette = 5=#97522c
|
||||
palette = 6=#989a9c
|
||||
palette = 7=#968c83
|
||||
palette = 8=#5e5252
|
||||
palette = 9=#be100e
|
||||
palette = 10=#858162
|
||||
palette = 11=#eaa549
|
||||
palette = 12=#426a79
|
||||
palette = 13=#97522c
|
||||
palette = 14=#989a9c
|
||||
palette = 15=#d5ccba
|
||||
background = 20111b
|
||||
foreground = 968c83
|
||||
cursor-color = 968c83
|
||||
selection-background = 45373c
|
||||
selection-foreground = 968c83
|
21
bin/share/ghostty/themes/BirdsOfParadise
Normal file
21
bin/share/ghostty/themes/BirdsOfParadise
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#573d26
|
||||
palette = 1=#be2d26
|
||||
palette = 2=#6ba18a
|
||||
palette = 3=#e99d2a
|
||||
palette = 4=#5a86ad
|
||||
palette = 5=#ac80a6
|
||||
palette = 6=#74a6ad
|
||||
palette = 7=#e0dbb7
|
||||
palette = 8=#9b6c4a
|
||||
palette = 9=#e84627
|
||||
palette = 10=#95d8ba
|
||||
palette = 11=#d0d150
|
||||
palette = 12=#b8d3ed
|
||||
palette = 13=#d19ecb
|
||||
palette = 14=#93cfd7
|
||||
palette = 15=#fff9d5
|
||||
background = 2a1f1d
|
||||
foreground = e0dbb7
|
||||
cursor-color = 573d26
|
||||
selection-background = 563c27
|
||||
selection-foreground = e0dbbb
|
21
bin/share/ghostty/themes/Blazer
Normal file
21
bin/share/ghostty/themes/Blazer
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#b87a7a
|
||||
palette = 2=#7ab87a
|
||||
palette = 3=#b8b87a
|
||||
palette = 4=#7a7ab8
|
||||
palette = 5=#b87ab8
|
||||
palette = 6=#7ab8b8
|
||||
palette = 7=#d9d9d9
|
||||
palette = 8=#262626
|
||||
palette = 9=#dbbdbd
|
||||
palette = 10=#bddbbd
|
||||
palette = 11=#dbdbbd
|
||||
palette = 12=#bdbddb
|
||||
palette = 13=#dbbddb
|
||||
palette = 14=#bddbdb
|
||||
palette = 15=#ffffff
|
||||
background = 0d1926
|
||||
foreground = d9e6f2
|
||||
cursor-color = d9e6f2
|
||||
selection-background = c1ddff
|
||||
selection-foreground = 000000
|
21
bin/share/ghostty/themes/Blue Matrix
Normal file
21
bin/share/ghostty/themes/Blue Matrix
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#101116
|
||||
palette = 1=#ff5680
|
||||
palette = 2=#00ff9c
|
||||
palette = 3=#fffc58
|
||||
palette = 4=#00b0ff
|
||||
palette = 5=#d57bff
|
||||
palette = 6=#76c1ff
|
||||
palette = 7=#c7c7c7
|
||||
palette = 8=#686868
|
||||
palette = 9=#ff6e67
|
||||
palette = 10=#5ffa68
|
||||
palette = 11=#fffc67
|
||||
palette = 12=#6871ff
|
||||
palette = 13=#d682ec
|
||||
palette = 14=#60fdff
|
||||
palette = 15=#ffffff
|
||||
background = 101116
|
||||
foreground = 00a2ff
|
||||
cursor-color = 76ff9f
|
||||
selection-background = c1deff
|
||||
selection-foreground = 000000
|
21
bin/share/ghostty/themes/BlueBerryPie
Normal file
21
bin/share/ghostty/themes/BlueBerryPie
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#0a4c62
|
||||
palette = 1=#99246e
|
||||
palette = 2=#5cb1b3
|
||||
palette = 3=#eab9a8
|
||||
palette = 4=#90a5bd
|
||||
palette = 5=#9d54a7
|
||||
palette = 6=#7e83cc
|
||||
palette = 7=#f0e8d6
|
||||
palette = 8=#201637
|
||||
palette = 9=#c87272
|
||||
palette = 10=#0a6c7e
|
||||
palette = 11=#7a3188
|
||||
palette = 12=#39173d
|
||||
palette = 13=#bc94b7
|
||||
palette = 14=#5e6071
|
||||
palette = 15=#0a6c7e
|
||||
background = 1c0c28
|
||||
foreground = babab9
|
||||
cursor-color = fcfad6
|
||||
selection-background = 606060
|
||||
selection-foreground = ffffff
|
21
bin/share/ghostty/themes/BlueDolphin
Normal file
21
bin/share/ghostty/themes/BlueDolphin
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#292d3e
|
||||
palette = 1=#ff8288
|
||||
palette = 2=#b4e88d
|
||||
palette = 3=#f4d69f
|
||||
palette = 4=#82aaff
|
||||
palette = 5=#e9c1ff
|
||||
palette = 6=#89ebff
|
||||
palette = 7=#d0d0d0
|
||||
palette = 8=#434758
|
||||
palette = 9=#ff8b92
|
||||
palette = 10=#ddffa7
|
||||
palette = 11=#ffe585
|
||||
palette = 12=#9cc4ff
|
||||
palette = 13=#ddb0f6
|
||||
palette = 14=#a3f7ff
|
||||
palette = 15=#ffffff
|
||||
background = 006984
|
||||
foreground = c5f2ff
|
||||
cursor-color = ffcc00
|
||||
selection-background = 2baeca
|
||||
selection-foreground = eceff1
|
21
bin/share/ghostty/themes/BlulocoDark
Normal file
21
bin/share/ghostty/themes/BlulocoDark
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#41444d
|
||||
palette = 1=#fc2f52
|
||||
palette = 2=#25a45c
|
||||
palette = 3=#ff936a
|
||||
palette = 4=#3476ff
|
||||
palette = 5=#7a82da
|
||||
palette = 6=#4483aa
|
||||
palette = 7=#cdd4e0
|
||||
palette = 8=#8f9aae
|
||||
palette = 9=#ff6480
|
||||
palette = 10=#3fc56b
|
||||
palette = 11=#f9c859
|
||||
palette = 12=#10b1fe
|
||||
palette = 13=#ff78f8
|
||||
palette = 14=#5fb9bc
|
||||
palette = 15=#ffffff
|
||||
background = 282c34
|
||||
foreground = b9c0cb
|
||||
cursor-color = ffcc00
|
||||
selection-background = b9c0ca
|
||||
selection-foreground = 272b33
|
21
bin/share/ghostty/themes/BlulocoLight
Normal file
21
bin/share/ghostty/themes/BlulocoLight
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#373a41
|
||||
palette = 1=#d52753
|
||||
palette = 2=#23974a
|
||||
palette = 3=#df631c
|
||||
palette = 4=#275fe4
|
||||
palette = 5=#823ff1
|
||||
palette = 6=#27618d
|
||||
palette = 7=#babbc2
|
||||
palette = 8=#676a77
|
||||
palette = 9=#ff6480
|
||||
palette = 10=#3cbc66
|
||||
palette = 11=#c5a332
|
||||
palette = 12=#0099e1
|
||||
palette = 13=#ce33c0
|
||||
palette = 14=#6d93bb
|
||||
palette = 15=#d3d3d3
|
||||
background = f9f9f9
|
||||
foreground = 373a41
|
||||
cursor-color = f32759
|
||||
selection-background = daf0ff
|
||||
selection-foreground = 373a41
|
21
bin/share/ghostty/themes/Borland
Normal file
21
bin/share/ghostty/themes/Borland
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#4f4f4f
|
||||
palette = 1=#ff6c60
|
||||
palette = 2=#a8ff60
|
||||
palette = 3=#ffffb6
|
||||
palette = 4=#96cbfe
|
||||
palette = 5=#ff73fd
|
||||
palette = 6=#c6c5fe
|
||||
palette = 7=#eeeeee
|
||||
palette = 8=#7c7c7c
|
||||
palette = 9=#ffb6b0
|
||||
palette = 10=#ceffac
|
||||
palette = 11=#ffffcc
|
||||
palette = 12=#b5dcff
|
||||
palette = 13=#ff9cfe
|
||||
palette = 14=#dfdffe
|
||||
palette = 15=#ffffff
|
||||
background = 0000a4
|
||||
foreground = ffff4e
|
||||
cursor-color = ffa560
|
||||
selection-background = a4a4a4
|
||||
selection-foreground = 0000a4
|
21
bin/share/ghostty/themes/Breeze
Normal file
21
bin/share/ghostty/themes/Breeze
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#31363b
|
||||
palette = 1=#ed1515
|
||||
palette = 2=#11d116
|
||||
palette = 3=#f67400
|
||||
palette = 4=#1d99f3
|
||||
palette = 5=#9b59b6
|
||||
palette = 6=#1abc9c
|
||||
palette = 7=#eff0f1
|
||||
palette = 8=#7f8c8d
|
||||
palette = 9=#c0392b
|
||||
palette = 10=#1cdc9a
|
||||
palette = 11=#fdbc4b
|
||||
palette = 12=#3daee9
|
||||
palette = 13=#8e44ad
|
||||
palette = 14=#16a085
|
||||
palette = 15=#fcfcfc
|
||||
background = 31363b
|
||||
foreground = eff0f1
|
||||
cursor-color = eff0f1
|
||||
selection-background = eff0f1
|
||||
selection-foreground = 31363b
|
21
bin/share/ghostty/themes/Bright Lights
Normal file
21
bin/share/ghostty/themes/Bright Lights
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#191919
|
||||
palette = 1=#ff355b
|
||||
palette = 2=#b7e876
|
||||
palette = 3=#ffc251
|
||||
palette = 4=#76d4ff
|
||||
palette = 5=#ba76e7
|
||||
palette = 6=#6cbfb5
|
||||
palette = 7=#c2c8d7
|
||||
palette = 8=#191919
|
||||
palette = 9=#ff355b
|
||||
palette = 10=#b7e876
|
||||
palette = 11=#ffc251
|
||||
palette = 12=#76d5ff
|
||||
palette = 13=#ba76e7
|
||||
palette = 14=#6cbfb5
|
||||
palette = 15=#c2c8d7
|
||||
background = 191919
|
||||
foreground = b3c9d7
|
||||
cursor-color = f34b00
|
||||
selection-background = b3c9d7
|
||||
selection-foreground = 191919
|
21
bin/share/ghostty/themes/Broadcast
Normal file
21
bin/share/ghostty/themes/Broadcast
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#da4939
|
||||
palette = 2=#519f50
|
||||
palette = 3=#ffd24a
|
||||
palette = 4=#6d9cbe
|
||||
palette = 5=#d0d0ff
|
||||
palette = 6=#6e9cbe
|
||||
palette = 7=#ffffff
|
||||
palette = 8=#323232
|
||||
palette = 9=#ff7b6b
|
||||
palette = 10=#83d182
|
||||
palette = 11=#ffff7c
|
||||
palette = 12=#9fcef0
|
||||
palette = 13=#ffffff
|
||||
palette = 14=#a0cef0
|
||||
palette = 15=#ffffff
|
||||
background = 2b2b2b
|
||||
foreground = e6e1dc
|
||||
cursor-color = ffffff
|
||||
selection-background = 5a647e
|
||||
selection-foreground = e6e1dc
|
21
bin/share/ghostty/themes/Brogrammer
Normal file
21
bin/share/ghostty/themes/Brogrammer
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#1f1f1f
|
||||
palette = 1=#f81118
|
||||
palette = 2=#2dc55e
|
||||
palette = 3=#ecba0f
|
||||
palette = 4=#2a84d2
|
||||
palette = 5=#4e5ab7
|
||||
palette = 6=#1081d6
|
||||
palette = 7=#d6dbe5
|
||||
palette = 8=#d6dbe5
|
||||
palette = 9=#de352e
|
||||
palette = 10=#1dd361
|
||||
palette = 11=#f3bd09
|
||||
palette = 12=#1081d6
|
||||
palette = 13=#5350b9
|
||||
palette = 14=#0f7ddb
|
||||
palette = 15=#ffffff
|
||||
background = 131313
|
||||
foreground = d6dbe5
|
||||
cursor-color = b9b9b9
|
||||
selection-background = 1f1f1f
|
||||
selection-foreground = d6dbe5
|
21
bin/share/ghostty/themes/Builtin Dark
Normal file
21
bin/share/ghostty/themes/Builtin Dark
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#bb0000
|
||||
palette = 2=#00bb00
|
||||
palette = 3=#bbbb00
|
||||
palette = 4=#0000bb
|
||||
palette = 5=#bb00bb
|
||||
palette = 6=#00bbbb
|
||||
palette = 7=#bbbbbb
|
||||
palette = 8=#555555
|
||||
palette = 9=#ff5555
|
||||
palette = 10=#55ff55
|
||||
palette = 11=#ffff55
|
||||
palette = 12=#5555ff
|
||||
palette = 13=#ff55ff
|
||||
palette = 14=#55ffff
|
||||
palette = 15=#ffffff
|
||||
background = 000000
|
||||
foreground = bbbbbb
|
||||
cursor-color = bbbbbb
|
||||
selection-background = b5d5ff
|
||||
selection-foreground = 000000
|
21
bin/share/ghostty/themes/Builtin Light
Normal file
21
bin/share/ghostty/themes/Builtin Light
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#000000
|
||||
palette = 1=#bb0000
|
||||
palette = 2=#00bb00
|
||||
palette = 3=#bbbb00
|
||||
palette = 4=#0000bb
|
||||
palette = 5=#bb00bb
|
||||
palette = 6=#00bbbb
|
||||
palette = 7=#bbbbbb
|
||||
palette = 8=#555555
|
||||
palette = 9=#ff5555
|
||||
palette = 10=#55ff55
|
||||
palette = 11=#ffff55
|
||||
palette = 12=#5555ff
|
||||
palette = 13=#ff55ff
|
||||
palette = 14=#55ffff
|
||||
palette = 15=#ffffff
|
||||
background = ffffff
|
||||
foreground = 000000
|
||||
cursor-color = 000000
|
||||
selection-background = b5d5ff
|
||||
selection-foreground = 000000
|
21
bin/share/ghostty/themes/Builtin Pastel Dark
Normal file
21
bin/share/ghostty/themes/Builtin Pastel Dark
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#4f4f4f
|
||||
palette = 1=#ff6c60
|
||||
palette = 2=#a8ff60
|
||||
palette = 3=#ffffb6
|
||||
palette = 4=#96cbfe
|
||||
palette = 5=#ff73fd
|
||||
palette = 6=#c6c5fe
|
||||
palette = 7=#eeeeee
|
||||
palette = 8=#7c7c7c
|
||||
palette = 9=#ffb6b0
|
||||
palette = 10=#ceffac
|
||||
palette = 11=#ffffcc
|
||||
palette = 12=#b5dcff
|
||||
palette = 13=#ff9cfe
|
||||
palette = 14=#dfdffe
|
||||
palette = 15=#ffffff
|
||||
background = 000000
|
||||
foreground = bbbbbb
|
||||
cursor-color = ffa560
|
||||
selection-background = 363983
|
||||
selection-foreground = f2f2f2
|
21
bin/share/ghostty/themes/Builtin Solarized Dark
Normal file
21
bin/share/ghostty/themes/Builtin Solarized Dark
Normal file
|
@ -0,0 +1,21 @@
|
|||
palette = 0=#073642
|
||||
palette = 1=#dc322f
|
||||
palette = 2=#859900
|
||||
palette = 3=#b58900
|
||||
palette = 4=#268bd2
|
||||
palette = 5=#d33682
|
||||
palette = 6=#2aa198
|
||||
palette = 7=#eee8d5
|
||||
palette = 8=#002b36
|
||||
palette = 9=#cb4b16
|
||||
palette = 10=#586e75
|
||||
palette = 11=#657b83
|
||||
palette = 12=#839496
|
||||
palette = 13=#6c71c4
|
||||
palette = 14=#93a1a1
|
||||
palette = 15=#fdf6e3
|
||||
background = 002b36
|
||||
foreground = 839496
|
||||
cursor-color = 839496
|
||||
selection-background = 073642
|
||||
selection-foreground = 93a1a1
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue