Home

Awesome

<div align="center">

~/. my dotfiles ~/. :house: 

> Managed with chezmoi :robot: 

</div>

:book:  Overview

This repository contains all my dotfiles managed by chezmoi. Please note that this is my own personal dotfiles. Stuffs may change without further notice and this README can get outdated.

:camera:  Screenshots

Sway sway

Tmux tmux

Fish prompt fish

Neovim nvim1 nvim2

:file_folder:  Included Plugins

:fish:  Fish

I use fisher as my plugin manager. These are the plugins I'm using:

To update fish plugins, type in fisher update in terminal. To install or remove fish plugins, you can run fisher command.

:memo:  Neovim

I use packer.nvim as my plugin manager. These are the plugins I'm using:

To update Neovim plugins, do :PackerSync in your nvim. Note: You need Neovim version >=0.7.0

:package:  Dependencies

You need to have these packages installed in your system if you want to set up:

For Sway:

waybar
grim
slurp
swayidle
python-i3ipc
rofi (optional)
nwg-dock (optional)

For i3

py3status
scrot
i3lock
picom (optional)
rofi (optional)
xfce4-panel (optional)

For Fish:

fish
git
fd
bat
chsh
fzf
zoxide
curl/wget
exa

For Neovim:

nvim
git
curl
npm
fzf
unzip

:abcd:  Fonts

Starship and Lualine requires powerline fonts to work. I suggest Nerd-fonts. The font in the screenshot above is using UbuntuMono Nerd Font Regular. I also need Unifont installed in the system for some glyphs to work. Chezmoi will do this automatically for you.

:inbox_tray:  Installation

Git clone this repository into your host machine: git clone https://github.com/budimanjojo/dotfiles.git Run install.sh: ./install.sh Then do chezmoi init --apply budimanjojo

:scroll:  Cheatsheet

Sway/i3 keybindings

I use Super and Alt key for Sway/i3. hjkl keys are mapped to left, down, up, right arrow keys. S means Super key, [0-9] means number key 0 to 9.

KeypressDescription
S+tOpen terminal app
S+wOpen browser
S+fOpen file manager
S+gOpen GIMP
S+bOpen OBS
S+sOpen Steam
S+graveOpen rofi apps menu
S+TabOpen rofi opened apps menu
Alt+F4Close window
S+F4Close window
Alt+kChange focus to window above
Alt+jChange focus to window below
Alt+hChange focus to left side window
Alt+lChange focus to right side window
Alt+Shift+kMove focused window up
Alt+Shift+jMove focused window down
Alt+Shift+hMove focused window left
Alt+Shift+lMove focused window right
Alt+Ctrl+hSplit opened windows horizontally
Alt+Ctrl+vSplit opened windows vertically
Alt+Ctrl+qToggle opened windows split
S+TabGo to next workspace
S+Shift+TabGo to previous workspace
Alt+Ctrl+tToggle window border on/off
Alt+Ctrl+gToggle gaps on/off
Alt+Ctrl+fToggle fullscreen mode on/off
Alt+Ctrl+sChange container layout to stacking
Alt+Ctrl+wChange container layout to tabbed
Alt+Ctrl+eToggle split layout to horizontal/vertical
S+Shift+SpaceToggle window floating on/off
S+SpaceSwap focus between tiling/floating window
S+Shift+-Move current focused window to scratchpad
S+-Show/hide scratchpad window
S+[0-9]Go to workspace #[0-9]
S+Shift+[0-9]Move focused window to workspace #[0-9]
Alt+Shift+rGo to resize container mode
Alt+Shift+gGo to resize gaps mode
Alt+Ctrl+DelGo to logout mode
PrintscreenGo to screenshot mode
S+Shift+cReload Sway configuration
S+Shift+eExit Sway

Neovim keybindings

The prefix key is Space. You can override this using your custom .vimrc.local file. <Leader> means you need to press prefix key first. If they are not in the table, that means it's using the default Vim keybindings.

ModeKeypressDescription
Normal<Leader>wSave file
Normal<Leader>xSave file and quit
Normal<Leader>qqQuit
Normal<Leader>qaForce quit without saving
Normal<Leader>wqSave file and quit
NormalYYank from cursor to end of file
InsertiiExit Insert mode
NormalKMove Up one paragraph
NormalJMove Down one paragraph
NormalHMove to the first character in line
NormalLMove to the last character in line
NormalControl+kMove to the split window above
NormalControl+jMove to the split window below
NormalControl+hMove to the left split window
NormalControl+lMove to the right split window
Normal<Leader>sOpen new horizontal split window
Normal<Leader>vOpen new vertical split window
InsertControl+kMove cursor Up
InsertControl+jMove cursor Down
InsertControl+hMove cursor Left
InsertControl+lMove cursor Right
Normal<Leader>tnOpen new tab
Normal<Leader>tdClose tab
Normal<Leader>thGo to previous tab
Normal<Leader>tlGo to next tab
Normal<Leader>teOpen new tab with current buffer's path
Normal<Leader>hhJump back to older cursor position
Normal<Leader>llJump forward to newer cursor position
Normal/VisualTabIndent current line or selection
Normal/VisualShift+TabDe-indent current line or selection
Normal<Leader>lrRestart LSP client
Normal<Leader>fzOpen FzfLua
Normal<Leader>ffOpen FzfLua to find files
Normal<Leader>fgOpen FzfLua to live grep
Normal<Leader>fcOpen FzfLua to see git commits
Normal<Leader>fbOpen FzfLua to see opened buffers
Normal<Leader>fhOpen FzfLua to find help
Normal<Leader>fkOpen FzfLua to see keymappings
Normal<Leader>feOpen FzfLua to find lsp diagnostics
Normal<Leader>frOpen FzfLua to find lsp references
Normal<Leader>fdOpen FzfLua to find lsp typedefs
Normal<Leader>xxToggle Trouble
Normal<Leader>xrToggle Trouble to find lsp references
NormalControl+fToggle lir.nvim file manager
Normal/TermControl+tToggle floating terminal
Normal<Leader>ppFormat buffer with null-ls
Visual<Leader>ppRange format buffer with null-ls
NormalrnDo LSP buffer rename
NormalgdDo LSP buffer get definition
NormalgDDo LSP buffer get declaration
NormalghDo LSP buffer get hover
NormalgrDo LSP buffer get references
NormalgiDo LSP buffer get implementation

Tmux keybindings

I override the default keybindings for Tmux to be more reasonable. Prefix key is Alt+a for local session and Alt+z for nested session. You can of course override this. <prefix> means you need to press prefix key first, <repeat> means you don't need to press prefix key again after triggering it within repeat-time set (default set to 1 second), <copy-mode> means you must be in copy-mode first. The table below lists all the keybindings set. If they are not in the table, that means it's using the default Tmux keybindings.

KeypressDescription
<prefix>Alt+eEdit tmux.conf.local file and reload configuration after saving
<prefix>Alt+rReload tmux configuration
<prefix>fFind session, window, pane from list
<prefix>Alt+sCreate new horizontal split window
<prefix>Alt+vCreate new vertical split window
<prefix>rRename current window
<prefix>RRename current session
<prefix><repeat>kMove selection to pane above
<prefix><repeat>jMove selection to pane below
<prefix><repeat>hMove selection to left pane
<prefix><repeat>lMove selection to right pane
<prefix><repeat>>Swap to next pane
<prefix><repeat><Swap to previous pane
<prefix><repeat>KResize current pane upwards
<prefix><repeat>JResize current pane downwards
<prefix><repeat>HResize current pane to the left
<prefix><repeat>LResize current pane to the right
<prefix><repeat>Alt+nMove selection to next window
<prefix><repeat>Alt+pMove selection to previous window
<prefix><repeat>TabMove selection to next window
<prefix>SJoin current pane to selected window in horizontal split
<prefix>VJoin current pane to selected window in vertical split
<prefix>xClose current pane
<prefix>XClose current window
<prefix>Alt+xClose all other windows
<prefix>aGet into copy mode
<prefix>pPaste copied text from last buffer
<prefix>PPaste copied text from list
<copy-mode>yCopy selected text
<copy-mode>YCopy the whole line of selected text
<copy-mode>DCopy till the end of line from selected text

Zellij keybindings

I'm migrating my tmux to Zellij. I mimicked my tmux configuration to work in zellij but not everything works the same. Prefix key is Alt+a, I use the "switch to normal mode" in zellij to achieve this. <normal> means you need to be in normal mode, <pane> means pane mode, and so on. The table below lists all the keybindings set.

KeypressDescription
<locked>Alt+aSwith to normal mode (act like prefix key in tmux)
<normal>Alt+sCreate new horizontal split window and back to locked mode
<normal>Alt+vCreate new vertical split window and back to locked mode
<normal>rSwitch to renametab mode
<normal>hMove selection to left pane
<normal>jMove selection to pane below
<normal>kMove selection to pane above
<normal>lMove selection to right pane
<normal>>Move pane around
<normal>HResize current pane upwards
<normal>JResize current pane downwards
<normal>HResize current pane to the left
<normal>LResize current pane to the right
<normal>Alt+nGo to next window
<normal>Alt+pGo to previous window
<normal>cOpen new tab and back to locked mode
<normal>xClose current pane and back to locked mode
<normal>aOpen pane with $EDITOR and back to locked mode
<normal>Esc/' '/"\n"Switch back to locked mode
<renametab>Alt+aSwitch to normal mode
<renametab>"\n"Switch to locked mode
<renametab>EscConfirm tab name and back to locked mode