diff --git a/config/ghostty/config b/config/ghostty/config index 85280779..b4a85836 100644 --- a/config/ghostty/config +++ b/config/ghostty/config @@ -22,6 +22,7 @@ shell-integration-features = no-cursor # Keyboard bindings keybind = f11=toggle_fullscreen keybind = shift+insert=paste_from_clipboard +keybind = control+insert=copy_to_clipboard # SSH session terminfo shell-integration-features = ssh-env diff --git a/config/kitty/kitty.conf b/config/kitty/kitty.conf index 5e2faf17..75be766a 100644 --- a/config/kitty/kitty.conf +++ b/config/kitty/kitty.conf @@ -14,6 +14,7 @@ confirm_os_window_close 0 # Keybindings map F11 toggle_fullscreen +map ctrl+insert copy_to_clipboard # Allow remote access single_instance yes @@ -23,7 +24,7 @@ allow_remote_control yes cursor_shape block enable_audio_bell no -# Minimal Tab bar styling +# Minimal Tab bar styling tab_bar_edge bottom tab_bar_style powerline tab_powerline_style slanted diff --git a/migrations/1759895423.sh b/migrations/1759895423.sh index 0b94a5b9..fcaeb417 100644 --- a/migrations/1759895423.sh +++ b/migrations/1759895423.sh @@ -1,3 +1,10 @@ -echo "Make shift+insert paste from clipboard" -sed -i '/keybind = f11=toggle_fullscreen/a keybind = shift+insert=paste_from_clipboard' ~/.config/ghostty/config +echo "Make shift+insert paste and ctrl+insert copy from clipboard in terminal" + +# Add keybindings to Alacritty sed -i 's/{ key = "F11", action = "ToggleFullscreen" }/{ key = "F11", action = "ToggleFullscreen" },\n{ key = "Insert", mods = "Shift", action = "Paste" },\n{ key = "Insert", mods = "Control", action = "Copy" }/' ~/.config/alacritty/alacritty.toml + +# Add keybindings to Ghostty +sed -i '/keybind = f11=toggle_fullscreen/a keybind = shift+insert=paste_from_clipboard\nkeybind = control+insert=copy_to_clipboard' ~/.config/ghostty/config + +# Add keybindings to Kitty +sed -i '/map F11 toggle_fullscreen/a map ctrl+insert copy_to_clipboard' ~/.config/kitty/kitty.conf