dotfiles

My dotfiles, nothing really interesting to see ...
git clone https://git.onna.be/dotfiles.git
Log | Files | Refs | README

config (8191B)


      1 # use 'Windows' key
      2 set $mod Mod4
      3 # Use Mouse+$mod to drag floating windows to their wanted position
      4 floating_modifier $mod
      5 # switch easily between 2 workspaces
      6 workspace_auto_back_and_forth yes
      7 
      8 # terminal setting
      9 set $term --no-startup-id urxvtc
     10 # system restart/shutdown
     11 set $shutdown doas /sbin/shutdown -h -p now
     12 set $reboot doas /sbin/reboot
     13 #
     14 ##For music (cmus)
     15 set $music cmus
     16 set $pause cmus-remote --pause
     17 set $play cmus-remote --play
     18 set $next cmus-remote --next
     19 set $prev cmus-remote --prev
     20 #For volume (mixerctl)
     21 set $volup --no-startup-id /home/paco/bin/volume.sh up
     22 set $voldown --no-startup-id /home/paco/bin/volume.sh down
     23 set $mute --no-startup-id /home/paco/bin/volume.sh mute
     24 
     25 # my font of choice
     26 font pango:Ubuntu Mono derivative Powerline 12
     27 
     28 ## Startup applications
     29 #Composite manager:
     30 exec --no-startup-id compton -bcCGf --backend glx --vsync opengl-swc --no-fading-openclose
     31 # backgrounds
     32 exec_always --no-startup-id feh --bg-fill ~/Pictures/noruega/GOPR1653.JPG
     33 # clipboard manager
     34 exec_always --no-startup-id parcellite
     35 # screensaver
     36 exec_always --no-startup-id xscreensaver -no-splash
     37 # notify daemon
     38 exec_always --no-startup-id dunst
     39 # we don't need the mouse cursor around ...
     40 exec_always --no-startup-id unclutter --timeout 10 --ignore-scrolling --fork
     41 
     42 
     43 ## some windows belong to a workspace
     44 assign [class="^Google-chrome$"] 2
     45 assign [class="^qutebrowser$"] 2
     46 assign [class="^Firefox$"] 2
     47 assign [class="^Gajim$"] 3
     48 assign [class="^mpv$"] 9
     49 assign [instance="mutt"] 5
     50 assign [instance="weechat"] 3
     51 assign [instance="nvim"] 4
     52 
     53 # don't want bar on chrome and some others
     54 for_window [class="^Google-chrome$"] border none
     55 for_window [class="^qutebrowser$"] border none
     56 for_window [class="^Firefox$"] border none
     57 for_window [class="^URxvt$"] border none
     58 # remmina is better floating
     59 for_window [instance="remmina"] floating enable
     60 for_window [instance="remmina"] move position center
     61 for_window [instance="remmina"] resize set 600 400
     62 # and zbar (barcode reader) too
     63 for_window [class="zbar"] floating enable
     64 for_window [class="zbar"] move position center
     65 # and ranger
     66 for_window [instance="^ranger$"] floating enable
     67 for_window [instance="^ranger$"] resize set 1500 800
     68 for_window [instance="^ranger$"] border pixel 2
     69 for_window [instance="^ranger$"] move position center
     70 # and Guvcview
     71 for_window [class="Guvcview"] floating enable
     72 for_window [class="Guvcview"] move position center
     73 for_window [class="Guvcview"] resize set 600 400
     74 # formula editor for Freecad
     75 for_window [class="Freecad" title="Formula editor"] floating enable
     76 for_window [class="Freecad" title="Formula editor"] move absolute position center
     77 # for_window [class="Freecad" title="Formula editor"] resize set 100 120
     78 for_window [class="Freecad" title="Formula editor"] border pixel 5
     79 # Gajim floating
     80 for_window [class="Gajim"] floating enable
     81 
     82 # comms workspace decoration
     83 for_window [instance="mutt"] border pixel 2
     84 for_window [instance="weechat"] border pixel 3
     85 
     86 # Dropdown/Scratchpad Windows (taken from https://github.com/LukeSmithxyz/voidrice)
     87 # First I have a tmux window used for background scripts.
     88 # I'll later bind this to mod+u.
     89 for_window [instance="dropdown"] floating enable
     90 for_window [instance="dropdown"] resize set 825 500
     91 for_window [instance="dropdown"] move scratchpad
     92 for_window [instance="dropdown"] border pixel 5
     93 exec $term -name dropdown
     94 
     95 ## Key bindings
     96 bindsym $mod+u [instance="dropdown"] scratchpad show; [instance="dropdown"] move position center
     97 # ranger file manager
     98 bindsym $mod+r exec $term -name ranger -e zsh -i -c ranger
     99 # start a terminal
    100 bindsym $mod+Return exec $term
    101 # editor
    102 bindsym $mod+v exec $term -name nvim -e zsh -i -c nvim
    103 # kill focused window
    104 bindsym $mod+Shift+q kill
    105 # system things shutdown/reboot
    106 bindsym $mod+Shift+BackSpace    exec $reboot
    107 bindsym $mod+Shift+x exec $shutdown
    108 # music
    109 bindsym $mod+m exec $music
    110 bindsym $mod+Shift+m exec $mute
    111 bindsym $mod+p exec $play
    112 bindsym $mod+Shift+p exec $pause
    113 bindsym $mod+n exec $next
    114 bindsym $mod+b exec $prev
    115 # Volume keys
    116 bindsym $mod+plus exec $volup
    117 bindsym $mod+Shift+plus exec $voldown
    118 # email and chat
    119 bindsym $mod+e exec $term -name mutt -e neomutt
    120 bindsym $mod+w exec $term -name weechat -e weechat
    121 # screenshots
    122 bindsym --release Print exec --no-startup-id maim -s ~/tmp/shots/shot_$(date +%Y%m%d%H%M%S).png
    123 bindsym Shift+Print exec --no-startup-id maim -u ~/tmp/shots/shot_$(date +%Y%m%d%H%M%S)_full.png
    124 # apps launcher
    125 bindsym $mod+d exec --no-startup-id ~/.config/rofi/launch.sh
    126 # change focus
    127 bindsym $mod+h focus left
    128 bindsym $mod+j focus down
    129 bindsym $mod+k focus up
    130 bindsym $mod+l focus right
    131 # alternatively, you can use the cursor keys:
    132 bindsym $mod+Left focus left
    133 bindsym $mod+Down focus down
    134 bindsym $mod+Up focus up
    135 bindsym $mod+Right focus right
    136 # move focused window
    137 bindsym $mod+Shift+h move left
    138 bindsym $mod+Shift+j move down
    139 bindsym $mod+Shift+k move up
    140 bindsym $mod+Shift+l move right
    141 # alternatively, you can use the cursor keys:
    142 bindsym $mod+Shift+Left move left
    143 bindsym $mod+Shift+Down move down
    144 bindsym $mod+Shift+Up move up
    145 bindsym $mod+Shift+Right move right
    146 # split in horizontal orientation
    147 bindsym $mod+Shift+bar split h
    148 bindsym $mod+bar layout splith
    149 # split in vertical orientation
    150 bindsym $mod+Shift+minus split v
    151 bindsym $mod+minus layout splitv
    152 # enter fullscreen mode for the focused container
    153 bindsym $mod+f fullscreen toggle
    154 # change container layout (stacked, tabbed, toggle split)
    155 bindsym $mod+s layout stacking
    156 bindsym $mod+t layout tabbed
    157 bindsym $mod+Shift+t layout toggle split
    158 # toggle tiling / floating
    159 bindsym $mod+Shift+space floating toggle
    160 # change focus between tiling / floating windows
    161 bindsym $mod+space focus mode_toggle
    162 # navigate workspaces
    163 bindsym $mod+1 workspace 1
    164 bindsym $mod+2 workspace 2
    165 bindsym $mod+3 workspace 3
    166 bindsym $mod+4 workspace 4
    167 bindsym $mod+5 workspace 5
    168 bindsym $mod+6 workspace 6
    169 bindsym $mod+7 workspace 7
    170 bindsym $mod+8 workspace 8
    171 bindsym $mod+9 workspace 9
    172 bindsym $mod+0 workspace 10
    173 # move focused container to workspace
    174 bindsym $mod+Shift+1 move container to workspace 1
    175 bindsym $mod+Shift+2 move container to workspace 2
    176 bindsym $mod+Shift+3 move container to workspace 3
    177 bindsym $mod+Shift+4 move container to workspace 4
    178 bindsym $mod+Shift+5 move container to workspace 5
    179 bindsym $mod+Shift+6 move container to workspace 6
    180 bindsym $mod+Shift+7 move container to workspace 7
    181 bindsym $mod+Shift+8 move container to workspace 8
    182 bindsym $mod+Shift+9 move container to workspace 9
    183 bindsym $mod+Shift+0 move container to workspace 10
    184 # reload the configuration file
    185 bindsym $mod+Shift+c reload
    186 # restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
    187 bindsym $mod+Shift+period restart
    188 # exit i3 (logs you out of your X session)
    189 bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"
    190 
    191 # resize window (you can also use the mouse for that)
    192 mode "resize" {
    193         # These bindings trigger as soon as you enter the resize mode
    194 
    195         # Pressing left will shrink the window’s width.
    196         # Pressing right will grow the window’s width.
    197         # Pressing up will shrink the window’s height.
    198         # Pressing down will grow the window’s height.
    199         bindsym h resize shrink width 10 px or 10 ppt
    200         bindsym j resize grow height 10 px or 10 ppt
    201         bindsym k resize shrink height 10 px or 10 ppt
    202         bindsym l resize grow width 10 px or 10 ppt
    203 
    204         # same bindings, but for the arrow keys
    205         bindsym Left resize shrink width 10 px or 10 ppt
    206         bindsym Down resize grow height 10 px or 10 ppt
    207         bindsym Up resize shrink height 10 px or 10 ppt
    208         bindsym Right resize grow width 10 px or 10 ppt
    209 
    210         # back to normal: Enter or Escape
    211         bindsym Return mode "default"
    212         bindsym Escape mode "default"
    213 }
    214 
    215 bindsym $mod+Shift+r mode "resize"
    216 
    217 # Start i3bar to display a workspace bar (plus the system information i3status
    218 # finds out, if available)
    219 bar {
    220         position top
    221         font pango:Ubuntu Mono derivative Powerline 12
    222         separator_symbol " | "
    223         status_command i3status
    224 }