Gabriel Capella 1 day ago
parent
commit
922d2addef

+ 18 - 0
dots/.config/alacritty/alacritty.toml

@@ -0,0 +1,18 @@
+[font]
+size = 11
+
+[font.bold]
+family = "JetBrainsMono"
+style = "Bold"
+
+[font.bold_italic]
+family = "JetBrainsMono"
+style = "Bold Italic"
+
+[font.italic]
+family = "JetBrainsMono"
+style = "Italic"
+
+[font.normal]
+family = "JetBrainsMono"
+style = "Regular"

+ 17 - 0
dots/.config/alacritty/alacritty.yml

@@ -0,0 +1,17 @@
+font:
+  normal:
+    style: Regular
+
+  bold:
+    family: terminal-font
+    style: Bold
+
+  italic:
+    family: terminal-font
+    style: Italic
+
+  bold_italic:
+    family: terminal-font
+    style: Bold Italic
+
+  size: 12

+ 0 - 0
dots/.config/alacritty/alacritty/alacritty.toml


+ 5 - 0
dots/.config/fish/conf.d/starting_dir.fish

@@ -0,0 +1,5 @@
+set -q fish_most_recent_dir && [ -d "$fish_most_recent_dir" ] && cd "$fish_most_recent_dir"
+
+function save_dir --on-variable PWD
+    set -U fish_most_recent_dir $PWD
+end

+ 3 - 2
dots/.config/fish/fish_variables

@@ -3,7 +3,7 @@
 SETUVAR __fish_classic_git_prompt_initialized:\x1d
 SETUVAR __fish_init_2_39_8:\x1d
 SETUVAR __fish_init_2_3_0:\x1d
-SETUVAR __fish_initialized:3400
+SETUVAR __fish_initialized:3800
 SETUVAR _fish_abbr_l:ls
 SETUVAR fish_color_autosuggestion:555
 SETUVAR fish_color_cancel:\x2dr
@@ -23,13 +23,14 @@ SETUVAR fish_color_operator:bryellow
 SETUVAR fish_color_param:00afff
 SETUVAR fish_color_quote:999900
 SETUVAR fish_color_redirection:00afff
-SETUVAR fish_color_search_match:bryellow\x1e\x2d\x2dbackground\x3dbrblack
+SETUVAR fish_color_search_match:white\x1e\x2d\x2dbackground\x3dbrblack
 SETUVAR fish_color_selection:white\x1e\x2d\x2dbold\x1e\x2d\x2dbackground\x3dbrblack
 SETUVAR fish_color_status:red
 SETUVAR fish_color_user:brgreen
 SETUVAR fish_color_valid_path:\x2d\x2dunderline
 SETUVAR fish_greeting:Capella
 SETUVAR fish_key_bindings:fish_vi_key_bindings
+SETUVAR fish_most_recent_dir:/home/capella/\x2edofiles/dotfiles
 SETUVAR fish_pager_color_completion:\x1d
 SETUVAR fish_pager_color_description:B3A06D\x1eyellow
 SETUVAR fish_pager_color_prefix:white\x1e\x2d\x2dbold\x1e\x2d\x2dunderline

+ 14 - 14
dots/.config/sway/config

@@ -23,11 +23,9 @@ font pango:B612 12
 
 # NetworkManager is the most popular way to manage wireless networks on Linux,
 # and nm-applet is a desktop environment-independent system tray GUI for it.
-exec --no-startup-id clipster -d
+exec wl-paste --watch cliphist store
 exec mako
 
-bindsym $mod+c exec clipster -sp
-
 # Use Mouse+$mod to drag floating windows to their wanted position
 floating_modifier $mod
 
@@ -41,12 +39,24 @@ bindsym $mod+Shift+q kill
 bindsym $mod+d exec bemenu-run -l 10 -p  --counter always -c -W 0.1 -B 10 \
     --fixed-height --fn  'B612 11'  \
     --bdr "#323232" --tf "#FFFFFF" --hf "#FFFFFF"
+bindsym $mod+Shift+v exec cliphist list | bemenu -l 10 -p  --counter always -c -W 0.1 -B 10 \
+    --fixed-height --fn  'B612 11'  \
+    --bdr "#323232" --tf "#FFFFFF" --hf "#FFFFFF" \
+    | cliphist decode | wl-copy
+
+# Copy and paste
+bindsym $mod+v exec ~/.config/sway/scripts/contextual-paste.sh
+bindsym $mod+c exec ~/.config/sway/scripts/contextual-copy.sh
+
+# focus the parent container
+bindsym $mod+a exec wtype -M ctrl -k a -m ctrl
+
 
 # change focus
 bindsym $mod+j focus left
 bindsym $mod+k focus down
 bindsym $mod+l focus up
-bindsym $mod+semicolon focus right
+bindsym $mod+h focus right
 
 # alternatively, you can use the cursor keys:
 bindsym $mod+Left focus left
@@ -66,13 +76,6 @@ bindsym $mod+Shift+Down move down
 bindsym $mod+Shift+Up move up
 bindsym $mod+Shift+Right move right
 
-# split in horizontal orientation
-bindsym $mod+h split h
-
-# split in vertical orientation
-bindsym $mod+v split v
-
-
 # enter fullscreen mode for the focused container
 bindsym $mod+f fullscreen toggle
 
@@ -87,9 +90,6 @@ bindsym $mod+Shift+space floating toggle
 # change focus between tiling / floating windows
 bindsym $mod+space focus mode_toggle
 
-# focus the parent container
-bindsym $mod+a focus parent
-
 # Define names for default workspaces for which we configure key bindings later on.
 # We use variables to avoid repeating the names in multiple places.
 set $ws1 "1"

+ 17 - 0
dots/.config/sway/scripts/contextual-copy.sh

@@ -0,0 +1,17 @@
+#!/bin/bash
+
+# Get focused app_id
+app_id=$(swaymsg -t get_tree | jq -r '
+  ..
+  | ((.nodes? + .floating_nodes?) // empty)
+  | .[] | select(.focused and .pid).app_id
+  ' -r)
+
+  echo $app_id
+
+if [[ "$app_id" == "Alacritty" ]]; then
+    wtype -M ctrl -M shift -k c -m shift -m ctrl
+else
+    wtype -M ctrl -k c -m ctrl
+fi
+

+ 17 - 0
dots/.config/sway/scripts/contextual-paste.sh

@@ -0,0 +1,17 @@
+#!/bin/bash
+
+# Get focused app_id
+app_id=$(swaymsg -t get_tree | jq -r '
+  ..
+  | ((.nodes? + .floating_nodes?) // empty)
+  | .[] | select(.focused and .pid).app_id
+  ' -r)
+
+  echo $app_id
+
+if [[ "$app_id" == "Alacritty" ]]; then
+    wtype -M ctrl -M shift -k v -m shift -m ctrl
+else
+    wtype -M ctrl -k v -m ctrl
+fi
+

+ 8 - 40
dots/.vimrc

@@ -1,4 +1,5 @@
 """""""""""""""""""""""""""""""""""""
+
 " Capella .vimrc
 """""""""""""""""""""""""""""""""""""
 set nocompatible              " be iMproved, required
@@ -22,7 +23,8 @@ Plugin 'colors'
 Plugin 'jistr/vim-nerdtree-tabs'
 Plugin 'iwonbigbro/vim-hybrid'
 Plugin 'dense-analysis/ale'
-Plugin 'ojroques/vim-oscyank'
+Plugin 'junegunn/fzf.vim'
+
 
 call vundle#end()
 filetype plugin indent on
@@ -43,7 +45,7 @@ set wildmenu
 set autoread
 set backspace=indent,eol,start
 
-" Show linenumbers
+" Show line numbers
 set number
 set noruler
 set cursorline
@@ -63,8 +65,9 @@ set list
 " Search
 set hlsearch
 set incsearch
+" nnoremap <silent> <Esc><Esc> :let @/=""<CR>
 
-" Theme and Styling 
+" Theme and Styling
 set t_Co=256
 set background=dark
 
@@ -82,46 +85,11 @@ let g:NERDTreeDirArrowCollapsible = '▾'
 """""""""""""""""""""""""""""""""""""
 " Colors 
 """""""""""""""""""""""""""""""""""""
-hi Normal          ctermfg=252 ctermbg=none
-hi CursorLine      ctermbg=236              cterm=none
-hi CursorLineNr    ctermfg=208              cterm=none
-
-hi Boolean         ctermfg=141
-hi Character       ctermfg=222
-hi Number          ctermfg=141
-hi String          ctermfg=222
-hi Conditional     ctermfg=197               cterm=bold
-hi Constant        ctermfg=141               cterm=bold
-
-hi DiffDelete      ctermfg=125 ctermbg=233
-
-hi Directory       ctermfg=154               cterm=bold
-hi Error           ctermfg=222 ctermbg=233
-hi Exception       ctermfg=154               cterm=bold
-hi Float           ctermfg=141
-hi Function        ctermfg=154
-hi Identifier      ctermfg=208
-
-hi Keyword         ctermfg=197               cterm=bold
-hi Operator        ctermfg=197
-hi PreCondit       ctermfg=154               cterm=bold
-hi PreProc         ctermfg=154
-hi Repeat          ctermfg=197               cterm=bold
-
-hi Statement       ctermfg=197               cterm=bold
-hi Tag             ctermfg=197
-hi Title           ctermfg=203
-hi Visual          ctermbg=238
-
-hi Comment         ctermfg=244
-hi LineNr          ctermfg=239 ctermbg=235
-hi NonText         ctermfg=239
-hi SpecialKey      ctermfg=239
-
 colorscheme hybrid
+hi MatchParen cterm=bold ctermbg=none ctermfg=yellow
+hi ColorColumn ctermbg=232 guibg=#2c2d27
 
 autocmd FileType nerdtree setlocal colorcolumn&
-highlight ColorColumn ctermbg=232 guibg=#2c2d27
 let &colorcolumn="".join(range(81,999),",")
 
 set splitright