Massive configuration overhaul
Currently paying the price of months of non-diligent git usage. Here's what has changed. - Theming support in Gvcci and wpgtk - Dropping support for i3 - Supporting EXWM - Many Elisp modules - Collapsed redundant directories in ./configs
This commit is contained in:
		
							parent
							
								
									a7c72adb2e
								
							
						
					
					
						commit
						6b456c1b7a
					
				
					 551 changed files with 88587 additions and 1392 deletions
				
			
		
							
								
								
									
										4
									
								
								Makefile
									
										
									
									
									
								
							
							
						
						
									
										4
									
								
								Makefile
									
										
									
									
									
								
							| 
						 | 
					@ -3,3 +3,7 @@ install:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
uninstall:
 | 
					uninstall:
 | 
				
			||||||
	source "${DOTFILES}/configs/uninstall"
 | 
						source "${DOTFILES}/configs/uninstall"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					list-broken-links:
 | 
				
			||||||
 | 
						find "${HOME}" -maxdepth 1 -xtype l && \
 | 
				
			||||||
 | 
						find "${HOME}/.config" -maxdepth 1 -xtype l
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
							
								
								
									
										177
									
								
								README.md
									
										
									
									
									
								
							
							
						
						
									
										177
									
								
								README.md
									
										
									
									
									
								
							| 
						 | 
					@ -6,8 +6,52 @@ other items.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Configuration is everything.
 | 
					Configuration is everything.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Installation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Setting up new computer
 | 
					## wpgtk and gvcci
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					$ apti python-pip3
 | 
				
			||||||
 | 
					$ gclone deviantfero/wpgtk
 | 
				
			||||||
 | 
					$ cd ..
 | 
				
			||||||
 | 
					$ gclone FabriceCastel/gvcci
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					- TODO: Ensure edits to `i3.base` work as expected.
 | 
				
			||||||
 | 
					- TODO: Integrate Emacs themes into wpgtk.
 | 
				
			||||||
 | 
					- TODO: Integrate Vim themes into wpgtk.
 | 
				
			||||||
 | 
					- TODO: add these to the install script
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					$ ln -s ~/Dropbox/.password-store ~/.password-store
 | 
				
			||||||
 | 
					$ ln -s ~/Dropbox/bin ~/bin
 | 
				
			||||||
 | 
					$ import_gpg $DOTFILES/configs/shared/gpg/.gnupg/exported
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					1. Clipmenu
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Clipmenu is a service to store a history of copied strings.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Install it as:
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					$ cd ~/programming && g clone cdown/clipmenu
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					- TODO: Include `~/.config/systemd/user` in `configs/shared`.
 | 
				
			||||||
 | 
					- TODO: Obviate installation.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Ensure that it runs on startup:
 | 
				
			||||||
 | 
					```bash
 | 
				
			||||||
 | 
					$ cd ~/programming/clipmenu
 | 
				
			||||||
 | 
					$ cp clipmenu clipmenud clipdel ~/bin # You may not need to do this step.
 | 
				
			||||||
 | 
					$ vim init/clipmenud.service
 | 
				
			||||||
 | 
					# Change the ExecStart line to point to ~/bin/clipmenud
 | 
				
			||||||
 | 
					$ cp init/clipmenud.service ~/.config/systemd/user/clipmenud.service
 | 
				
			||||||
 | 
					$ systemctl --user start clipmenud
 | 
				
			||||||
 | 
					$ systemctl --user enable clipmenud # This step may be optional.
 | 
				
			||||||
 | 
					$ reboot
 | 
				
			||||||
 | 
					$ systemctl --user status clipmenud # Verify installation worked.
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
1. Install Dropbox
 | 
					1. Install Dropbox
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -20,7 +64,7 @@ $ pgrep dropbox     # 2/3 verify installation
 | 
				
			||||||
$ dropbox.py status # 3/3 verify installation
 | 
					$ dropbox.py status # 3/3 verify installation
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
1. Authorize computer to access dotfiles
 | 
					1. Authorize computer to access GitHub
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
$ ssh-keygen -t rsa -b 4096 -C 'wpcarro@gmail.com'
 | 
					$ ssh-keygen -t rsa -b 4096 -C 'wpcarro@gmail.com'
 | 
				
			||||||
| 
						 | 
					@ -28,46 +72,19 @@ $ eval $(ssh-agent -s)
 | 
				
			||||||
$ ssh-add ~/.ssh/id_rsa
 | 
					$ ssh-add ~/.ssh/id_rsa
 | 
				
			||||||
$ xclip -sel clip <~/.ssh/id_rsa.pub
 | 
					$ xclip -sel clip <~/.ssh/id_rsa.pub
 | 
				
			||||||
$ browse github.com # paste ssh public key in settings
 | 
					$ browse github.com # paste ssh public key in settings
 | 
				
			||||||
$ mkdir ~/programming
 | 
					 | 
				
			||||||
$ git clone git@github.com:wpcarro/dotfiles ~/Dropbox/dotfiles
 | 
					 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
1. Install Antigen, Vundle, nix-env for package management
 | 
					1. Install Antigen, Vundle, nix-env
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
$ # antigen
 | 
					$ ln -s ~/Dropbox/antigen.zsh ~/antigen.zsh
 | 
				
			||||||
$ curl -L git.io/antigen >~/antigen.zsh
 | 
					$ ln -s ~/Dropbox/Vundle.vim ~/.config/nvim/bundle/Vundle.vim
 | 
				
			||||||
$ # vundle
 | 
					$ cat ~/Dropbox/install_nix.sh | sh
 | 
				
			||||||
$ g clone VundleVim/Vundle.vim ~/.config/nvim/bundle/Vundle.vim
 | 
					 | 
				
			||||||
$ # nix-env
 | 
					 | 
				
			||||||
$ curl https://nixos.org/nix/install | sh
 | 
					 | 
				
			||||||
$ for p in $(cat nix-env.txt); do
 | 
					$ for p in $(cat nix-env.txt); do
 | 
				
			||||||
>   nix-env -i "$p"
 | 
					>   nix-env -i "$p"
 | 
				
			||||||
> done
 | 
					> done
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
1. Install shared executables
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
Some files should be kept out of this repository. Things that come to mind
 | 
					 | 
				
			||||||
include secrets (e.g. `monzo_creds.json.gpg`) and binaries.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
Secrets should be kept out of this repository in case. It might be okay to
 | 
					 | 
				
			||||||
include them herein since they should be encrypted. But just to add an
 | 
					 | 
				
			||||||
additional layer of security, I avoid adding them.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
Executables are kept out of version control since they can be quite large. For
 | 
					 | 
				
			||||||
example, my `/usr/bin` is `8.9G` at the time of this writing. Also it can be
 | 
					 | 
				
			||||||
noisy to see diffs of binaries after upgrading programs.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
While sharing binaries across systems feels brittle, everything should function
 | 
					 | 
				
			||||||
as long as the machines across which the binaries are shared run Linux and have
 | 
					 | 
				
			||||||
i386 architectures.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
```bash
 | 
					 | 
				
			||||||
$ ln -s ~/Dropbox/bin ~/bin
 | 
					 | 
				
			||||||
```
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
1. Install i3
 | 
					1. Install i3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
| 
						 | 
					@ -76,18 +93,39 @@ $ sudo apt-get install i3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
1. Install dotfiles
 | 
					1. Install dotfiles
 | 
				
			||||||
 | 
					
 | 
				
			||||||
TODO: include steps 2-4 in the `make install` command.
 | 
					- TODO: include steps 2-4 in the `make install` command.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Missing the following dependencies:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					- `stow`
 | 
				
			||||||
 | 
					- `neovim`
 | 
				
			||||||
 | 
					- `bat`
 | 
				
			||||||
 | 
					- `exa`
 | 
				
			||||||
 | 
					- `fasd`
 | 
				
			||||||
 | 
					- `opam`
 | 
				
			||||||
 | 
					- `ghcup`
 | 
				
			||||||
 | 
					- `ripgrep`
 | 
				
			||||||
 | 
					- `fzf`
 | 
				
			||||||
 | 
					- `fd`
 | 
				
			||||||
 | 
					- `hub`
 | 
				
			||||||
 | 
					- `pass`
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
$ cd ~/Dropbox/dotfiles
 | 
					$ cd ~/Dropbox/dotfiles
 | 
				
			||||||
$ DOTFILES="$(pwd)" make install
 | 
					$ DOTFILES="$(pwd)" make install
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					1. Install Node dependencies
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# TODOS
 | 
					For now, this deserves its own section since it isn't automated.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
- support dependencies like terminal themes
 | 
					```zsh
 | 
				
			||||||
 | 
					gclone tj/n       # clone repo
 | 
				
			||||||
 | 
					sudo make install # build from source
 | 
				
			||||||
 | 
					n stable          # install the stable version of node
 | 
				
			||||||
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					- TODO: support dependencies like terminal themes
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# SSHFS
 | 
					# SSHFS
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -122,16 +160,16 @@ manually SSH into that machine.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# GnuPG
 | 
					# GnuPG
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Entering a new system?
 | 
					To install GPG run the following:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
$ ./configs/shared/gpg/.gnupg/import.sh path/to/directory
 | 
					$ import_gpg
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
Leaving an old system? TODO: create a job that runs this periodically.
 | 
					TODO: create a job that runs this periodically.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
$ ./configs/shared/gpg/.gnupg/export.sh [directory]
 | 
					$ export_gpg
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
## Reference
 | 
					## Reference
 | 
				
			||||||
| 
						 | 
					@ -141,66 +179,19 @@ $ ./configs/shared/gpg/.gnupg/export.sh [directory]
 | 
				
			||||||
    - ssb: secret sub-key
 | 
					    - ssb: secret sub-key
 | 
				
			||||||
    - sub: public sub-key
 | 
					    - sub: public sub-key
 | 
				
			||||||
 | 
					
 | 
				
			||||||
## GnuPG + Git
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
  1. Register newly created `[S]` signing subkey as `signingkey`
 | 
					## Terminals and Fonts
 | 
				
			||||||
  1. Enforce commit-signing
 | 
					 | 
				
			||||||
  1. Opt into `gpg2` usage
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					Any terminal or font I choose should pass the following checks:
 | 
				
			||||||
$ git config --global user.signingkey <SIGNING_KEY>
 | 
					 | 
				
			||||||
$ git config --global commit.gpgsign true
 | 
					 | 
				
			||||||
$ git config --global gpg.program gpg2
 | 
					 | 
				
			||||||
```
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
## GnuPG + GPG-Agent
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
Setup `gpg-agent` to use password caching by adding the following entries to
 | 
					 | 
				
			||||||
`~/.gnupg/gpg-agent.conf` (already done in this repository):
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
```
 | 
					 | 
				
			||||||
default-cache-ttl 300 max-cache-ttl 3600
 | 
					 | 
				
			||||||
```
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
## True Color and Italics
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
At the time of this writing, Suckless's `st` terminal provides True Color and
 | 
					 | 
				
			||||||
italics support. It's also important to test that this support remains when
 | 
					 | 
				
			||||||
inside of Vim or inside of a Tmux session or both.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
### TrueColor
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
To test for your terminal's True Color support, run:
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
```bash
 | 
					```bash
 | 
				
			||||||
$ test_true_color
 | 
					$ test_true_color
 | 
				
			||||||
```
 | 
					$ test_16_colors
 | 
				
			||||||
 | 
					 | 
				
			||||||
Enable TrueColor in your `init.vim` (already done in this repository):
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
```viml
 | 
					 | 
				
			||||||
set termguicolors
 | 
					 | 
				
			||||||
```
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
### Italics
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
To test if your terminal supports italics and other text treatments, run:
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
```bash
 | 
					 | 
				
			||||||
$ test_text_formatting
 | 
					$ test_text_formatting
 | 
				
			||||||
 | 
					$ test_unicode
 | 
				
			||||||
 | 
					$ test_emojis
 | 
				
			||||||
```
 | 
					```
 | 
				
			||||||
 | 
					
 | 
				
			||||||
### Ligatures
 | 
					### Ligatures
 | 
				
			||||||
 | 
					
 | 
				
			||||||
At the time of this writing, Suckless's `st` does not appear to support
 | 
					If using a font with ligature (e.g. Hasklig) assert that your terminal also support ligatures.
 | 
				
			||||||
ligatures.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
## Miscellaneous notes
 | 
					 | 
				
			||||||
* Executables are shared at `~/Dropbox/bin` and not kept within this repository
 | 
					 | 
				
			||||||
  to avoid the bloat.
 | 
					 | 
				
			||||||
* Map `<CAPS_LOCK>` key to `<ESC>`
 | 
					 | 
				
			||||||
* Increase key-repeat rate
 | 
					 | 
				
			||||||
* Decrease key-repeat-delay
 | 
					 | 
				
			||||||
* Increase mouse speed
 | 
					 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,3 +1,6 @@
 | 
				
			||||||
reddit.com/r/unixporn
 | 
					reddit.com/r/unixporn
 | 
				
			||||||
reddit.com/r/nixos
 | 
					reddit.com/r/nixos
 | 
				
			||||||
news.ycombinator.com
 | 
					news.ycombinator.com
 | 
				
			||||||
 | 
					gmail.com
 | 
				
			||||||
 | 
					github.com
 | 
				
			||||||
 | 
					github.com/wpcarro
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,14 +0,0 @@
 | 
				
			||||||
# Desktop-specific configuration
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# Since the keyboard for my desktop doesn't support XFree86 keysyms, prefer
 | 
					 | 
				
			||||||
# alternative KBDs.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# volume controls
 | 
					 | 
				
			||||||
bindsym F1 exec --no-startup-id pactl set-sink-mute   @DEFAULT_SINK@ toggle # same Fn keys as laptop
 | 
					 | 
				
			||||||
bindsym F2 exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10%   # same Fn keys as laptop
 | 
					 | 
				
			||||||
bindsym F3 exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10%   # same Fn keys as laptop
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# playback controls
 | 
					 | 
				
			||||||
bindsym F4 exec --no-startup-id playerctl previous   # same Fn keys as laptop
 | 
					 | 
				
			||||||
bindsym F5 exec --no-startup-id playerctl play-pause # same Fn keys as laptop
 | 
					 | 
				
			||||||
bindsym F6 exec --no-startup-id playerctl next       # same Fn keys as laptop
 | 
					 | 
				
			||||||
| 
						 | 
					@ -5,13 +5,16 @@ configs="$DOTFILES/configs"
 | 
				
			||||||
case $(hostname) in
 | 
					case $(hostname) in
 | 
				
			||||||
  # desktop
 | 
					  # desktop
 | 
				
			||||||
  wpcarro.lon.corp.google.com)
 | 
					  wpcarro.lon.corp.google.com)
 | 
				
			||||||
    (cd "$configs/desktop" && stow --target="$HOME" *);;
 | 
					    (cd "$configs/desktop" && stow --target="$HOME" .);;
 | 
				
			||||||
  # laptop
 | 
					  # laptop
 | 
				
			||||||
  wpcarro)
 | 
					  wpcarro2)
 | 
				
			||||||
    (cd "$configs/laptop" && stow --target="$HOME" *);;
 | 
					    (cd "$configs/work_laptop" && stow --target="$HOME" .);;
 | 
				
			||||||
  # cloudtop
 | 
					  # cloudtop
 | 
				
			||||||
  wpcarro.c.googlers.com)
 | 
					  wpcarro.c.googlers.com)
 | 
				
			||||||
    (cd "$configs/cloudtop" && stow --target="$HOME" *);;
 | 
					    (cd "$configs/cloudtop" && stow --target="$HOME" .);;
 | 
				
			||||||
 | 
					  # Acer Manjaro laptop
 | 
				
			||||||
 | 
					  acer-manjaro)
 | 
				
			||||||
 | 
					    (cd "$configs/personal_laptop" && stow --target="$HOME" .);;
 | 
				
			||||||
esac
 | 
					esac
 | 
				
			||||||
 | 
					
 | 
				
			||||||
(cd "$configs/shared" && stow --target="$HOME" *)
 | 
					(cd "$configs/shared" && stow --target="$HOME" .)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,21 +0,0 @@
 | 
				
			||||||
# Laptop-specific configuration
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# My laptop has keys for XFree86 signals that my desktop keyboard currently
 | 
					 | 
				
			||||||
# doesn't have.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# volume controls
 | 
					 | 
				
			||||||
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10%   # MBP Volume Up
 | 
					 | 
				
			||||||
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10%   # MBP Volume Down
 | 
					 | 
				
			||||||
bindsym XF86AudioMute        exec --no-startup-id pactl set-sink-mute   @DEFAULT_SINK@ toggle # MBP Mute
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# playback controls
 | 
					 | 
				
			||||||
bindsym XF86AudioPrev exec --no-startup-id playerctl previous
 | 
					 | 
				
			||||||
bindsym XF86AudioPlay exec --no-startup-id playerctl play-pause
 | 
					 | 
				
			||||||
bindsym XF86AudioNext exec --no-startup-id playerctl next
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# screen brightness controls
 | 
					 | 
				
			||||||
bindsym XF86MonBrightnessUp   exec xbacklight -inc 15
 | 
					 | 
				
			||||||
bindsym XF86MonBrightnessDown exec xbacklight -dec 15
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# suspend laptop
 | 
					 | 
				
			||||||
bindsym Ctrl+Escape exec systemctl suspend
 | 
					 | 
				
			||||||
| 
						 | 
					@ -1 +0,0 @@
 | 
				
			||||||
Xft.dpi: 200
 | 
					 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/personal_laptop/.Xresources.device
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/personal_laptop/.Xresources.device
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					XTerm.vt100.faceName: GohuFont
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.Xresources.shared
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.Xresources.shared
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					! Put shared configuration here
 | 
				
			||||||
| 
						 | 
					@ -1,12 +1,15 @@
 | 
				
			||||||
# shadow
 | 
					# shadow
 | 
				
			||||||
shadow = true;
 | 
					shadow = false;
 | 
				
			||||||
shadow-radius = 7;
 | 
					shadow-radius = 7;
 | 
				
			||||||
shadow-offset-x = -7;
 | 
					shadow-offset-x = -7;
 | 
				
			||||||
shadow-offset-y = -7;
 | 
					shadow-offset-y = -7;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# TODO: Remove active opacity
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# opacity
 | 
					# opacity
 | 
				
			||||||
menu-opacity = 0.8;
 | 
					menu-opacity = 0.8;
 | 
				
			||||||
inactive-opacity = 0.8;
 | 
					inactive-opacity = 0.96;
 | 
				
			||||||
 | 
					active-opacity = 0.96;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# transitions
 | 
					# transitions
 | 
				
			||||||
fading = true;
 | 
					fading = true;
 | 
				
			||||||
| 
						 | 
					@ -21,4 +24,10 @@ fade-out-step = 0.07;
 | 
				
			||||||
#
 | 
					#
 | 
				
			||||||
# NOTE: For some reason, `100:class_g` doesn't work, so settling for
 | 
					# NOTE: For some reason, `100:class_g` doesn't work, so settling for
 | 
				
			||||||
# `99:class_g` instead.
 | 
					# `99:class_g` instead.
 | 
				
			||||||
opacity-rule = [ "99:class_g = 'xsecurelock'" ];
 | 
					opacity-rule = [
 | 
				
			||||||
 | 
					  "99:class_g = 'xsecurelock'",
 | 
				
			||||||
 | 
					  # TODO: Ensure this works.
 | 
				
			||||||
 | 
					  "80:class_g = 'terminator'",
 | 
				
			||||||
 | 
					  # TODO: Ensure this work.
 | 
				
			||||||
 | 
					  "80:class_g = 'Google Emacs'"
 | 
				
			||||||
 | 
					];
 | 
				
			||||||
| 
						 | 
					@ -13,24 +13,36 @@
 | 
				
			||||||
# KBDs my feeble memory needs to store.
 | 
					# KBDs my feeble memory needs to store.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
set $mod Mod1
 | 
					set $mod Mod1
 | 
				
			||||||
 | 
					set $window Mod1+Ctrl
 | 
				
			||||||
set $super Mod4
 | 
					set $super Mod4
 | 
				
			||||||
 | 
					set $terminal terminator
 | 
				
			||||||
 | 
					set $browser  google-chrome
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Font for window titles. Will also be used by the bar unless a different font
 | 
					# Font for window titles. Will also be used by the bar unless a different font
 | 
				
			||||||
# is used in the bar {} block below.
 | 
					# is used in the bar block below.
 | 
				
			||||||
font pango:monospace 8
 | 
					font pango:Monospace 10px
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Use Mouse+$mod to drag floating windows to their wanted position
 | 
					# Use Mouse+$mod to drag floating windows to their wanted position
 | 
				
			||||||
floating_modifier $mod
 | 
					floating_modifier $mod
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# i3-gaps (depends on i3-gaps installation)
 | 
					# i3-gaps (depends on i3-gaps installation)
 | 
				
			||||||
gaps inner 20
 | 
					# gaps inner 7
 | 
				
			||||||
gaps outer 0
 | 
					# gaps outer 0
 | 
				
			||||||
smart_gaps on
 | 
					# smart_gaps on
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# bindsym $mod+Ctrl+plus   gaps outer current plus  5
 | 
				
			||||||
 | 
					# bindsym $mod+Ctrl+minus  gaps outer current minus 5
 | 
				
			||||||
 | 
					# bindsym $mod+Shift+plus  gaps inner current plus  5
 | 
				
			||||||
 | 
					# bindsym $mod+Shift+minus gaps inner current minus 5
 | 
				
			||||||
 | 
					
 | 
				
			||||||
bindsym $mod+Ctrl+plus   gaps outer current plus  5
 | 
					# Support XF86 keys for audio playback and volume control
 | 
				
			||||||
bindsym $mod+Ctrl+minus  gaps outer current minus 5
 | 
					bindsym XF86AudioMute        exec --no-startup-id pactl set-sink-mute   @DEFAULT_SINK@ toggle
 | 
				
			||||||
bindsym $mod+Shift+plus  gaps inner current plus  5
 | 
					bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10%
 | 
				
			||||||
bindsym $mod+Shift+minus gaps inner current minus 5
 | 
					bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10%
 | 
				
			||||||
 | 
					bindsym XF86AudioPrev        exec --no-startup-id playerctl previous
 | 
				
			||||||
 | 
					bindsym XF86AudioNext        exec --no-startup-id playerctl next
 | 
				
			||||||
 | 
					bindsym XF86AudioStop        exec --no-startup-id playerctl play-pause
 | 
				
			||||||
 | 
					bindsym XF86AudioPlay        exec --no-startup-id playerctl play-pause
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# KBD Principles:
 | 
					# KBD Principles:
 | 
				
			||||||
# $mod+Ctrl+<app_char>       = starting an application
 | 
					# $mod+Ctrl+<app_char>       = starting an application
 | 
				
			||||||
| 
						 | 
					@ -42,45 +54,65 @@ bindsym $mod+Shift+minus gaps inner current minus 5
 | 
				
			||||||
# chrome   = c
 | 
					# chrome   = c
 | 
				
			||||||
# spotify  = s
 | 
					# spotify  = s
 | 
				
			||||||
# intellij = i
 | 
					# intellij = i
 | 
				
			||||||
#
 | 
					bindsym $mod+Ctrl+t exec $terminal
 | 
				
			||||||
# Vertical
 | 
					bindsym $mod+Return exec $terminal
 | 
				
			||||||
bindsym $mod+Ctrl+t      exec st
 | 
					bindsym $mod+Ctrl+e exec emacsclient --create-frame
 | 
				
			||||||
bindsym $mod+Ctrl+Return exec st
 | 
					bindsym $mod+Ctrl+c exec $browser
 | 
				
			||||||
bindsym $mod+Ctrl+e      exec emacsclient --create-frame ~/programming
 | 
					 | 
				
			||||||
bindsym $mod+Ctrl+c      exec google-chrome
 | 
					 | 
				
			||||||
bindsym $mod+Ctrl+s exec spotify
 | 
					bindsym $mod+Ctrl+s exec spotify
 | 
				
			||||||
bindsym $mod+Ctrl+i exec zsh -i -c intellij
 | 
					bindsym $mod+Ctrl+i exec zsh -i -c intellij
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# support dmenu-based bookmarks
 | 
					# support dmenu-based bookmarks
 | 
				
			||||||
bindsym $mod+Ctrl+b exec dmenu <$DOTFILES/bookmarks.txt | xargs $BROWSER
 | 
					# bindsym $mod+Ctrl+b exec rofi -dmenu <$DOTFILES/bookmarks.txt | xargs $browser
 | 
				
			||||||
 | 
					
 | 
				
			||||||
bindsym $mod+Return exec st
 | 
					set $bookmarks_mode Bookmarks (a) add, (d) delete, (b) browse
 | 
				
			||||||
 | 
					mode "$bookmarks_mode" {
 | 
				
			||||||
 | 
					     bindsym a exec zsh -i -c add_bookmark,  mode "default"
 | 
				
			||||||
 | 
					     bindsym d exec zsh -i -c rm_bookmark,   mode "default"
 | 
				
			||||||
 | 
					     bindsym b exec zsh -i -c open_bookmark, mode "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					     bindsym Escape mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+b mode "$bookmarks_mode"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# pass integration
 | 
					# pass integration
 | 
				
			||||||
bindsym $mod+Ctrl+backslash exec ~/.config/i3/passmenu # mirroring the 1password KBD
 | 
					bindsym $mod+Ctrl+backslash exec ~/.config/i3/passmenu # mirroring the 1password KBD
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# integrate with Emacs's org-mode
 | 
					# integrate with Emacs's org-mode
 | 
				
			||||||
bindsym $mod+o exec zsh -i -c org_capture
 | 
					bindsym $mod+o exec zsh -i -c org_capture
 | 
				
			||||||
for_window [class="GoogleEmacs" instance="org-protocol-capture"] floating enable
 | 
					# TODO: Support "coding size", "dialog-size" (for org_capture)
 | 
				
			||||||
 | 
					# TODO: Support way to cycle through predefined sizes.
 | 
				
			||||||
 | 
					for_window [class="GoogleEmacs" instance="floating"] floating enable, resize set height 1200px, resize set width 780px
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Here is a sketch of the cycle sizes idea.
 | 
				
			||||||
 | 
					# TODO: Support this.
 | 
				
			||||||
 | 
					# mode "cycle_sizes_floating_mode" {
 | 
				
			||||||
 | 
					#      # coding mode
 | 
				
			||||||
 | 
					#      bindsym a for_window [mode="floating", class="actively-selected"] resize set height 1200px, resize set width 780px
 | 
				
			||||||
 | 
					#      bindsym b for_window [mode="floating", class="actively-selected"] resize set height 500px, resize set width 500px
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					#      bindsym Escape mode "default"
 | 
				
			||||||
 | 
					#      bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					#      bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					# }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# ensure Spotify windows float
 | 
					# ensure Spotify windows float
 | 
				
			||||||
for_window [class="Spotify"] floating enable
 | 
					for_window [class="Spotify"] floating enable
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# ensure `lf` instances float
 | 
					 | 
				
			||||||
for_window [title="lf"] floating enable
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# ensure wallpaper
 | 
					 | 
				
			||||||
exec --no-startup-id feh --bg-scale ~/.local/share/wallpaper/cartoon-outdoors.jpg
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# ensure system service that run through XDG start
 | 
					# ensure system service that run through XDG start
 | 
				
			||||||
exec dex -ae i3
 | 
					exec --no-startup-id dex -ae i3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# dmenu configuration
 | 
					# rofi configuration
 | 
				
			||||||
bindsym $mod+space exec --no-startup-id dmenu_run
 | 
					bindsym $mod+space exec --no-startup-id rofi -show combi
 | 
				
			||||||
bindsym $mod+t     exec --no-startup-id ~/.config/i3/dmenu_timer.sh ~/.local/share/sounds/gong.mp3
 | 
					bindsym $mod+t     exec --no-startup-id ~/.config/i3/dmenu_timer.sh ~/.local/share/sounds/gong.mp3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# switch workspaces
 | 
				
			||||||
 | 
					bindsym $mod+Tab       workspace next
 | 
				
			||||||
 | 
					bindsym $mod+Shift+Tab workspace prev
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# file manager
 | 
					# file manager
 | 
				
			||||||
bindsym $mod+n exec st -e lf ~/Dropbox
 | 
					bindsym $mod+n exec $terminal -x lf ~/Dropbox
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# clipboard manager
 | 
					# clipboard manager
 | 
				
			||||||
# NOTE: Ctrl-c is already covered since `clipmenu` listens for X clipboard
 | 
					# NOTE: Ctrl-c is already covered since `clipmenu` listens for X clipboard
 | 
				
			||||||
| 
						 | 
					@ -93,23 +125,33 @@ bindsym $mod+n exec st -e lf ~/Dropbox
 | 
				
			||||||
bindsym Ctrl+$mod+v exec clipmenu && xdotool key --clearmodifiers ctrl+Shift+v
 | 
					bindsym Ctrl+$mod+v exec clipmenu && xdotool key --clearmodifiers ctrl+Shift+v
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Screenshot
 | 
					# Screenshot
 | 
				
			||||||
# TODO: find a better KBD for this
 | 
					# TODO: Support variants: (a) App (r) Region (f) Fullscreen.
 | 
				
			||||||
bindsym $mod+s exec zsh -i -c snipit # note that this eclipses Tmux's M-s KBD for switching b/w session
 | 
					# TODO: Support hosting to third-party image hosting.
 | 
				
			||||||
bindsym Ctrl+Print   exec scrot ~/Pictures/screenshots/%b-%d-%Y_%T.png # Windows style
 | 
					set $screenshot_mode Screenshot (g) googleplex (l) local
 | 
				
			||||||
# TODO: debug
 | 
					mode "$screenshot_mode" {
 | 
				
			||||||
# bindsym $mod+Print   exec scrot --focused ~/Pictures/screenshots/%b-%d-%Y_%T.png # Windows style
 | 
					     bindsym g exec zsh -i -c snipit,     mode "default"
 | 
				
			||||||
 | 
					     bindsym l exec zsh -i -c screenshot, mode "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					     bindsym Escape mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym $mod+s mode "$screenshot_mode"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# online documentation
 | 
					# online documentation
 | 
				
			||||||
bindsym $mod+Shift+slash exec google-chrome https://i3wm.org/docs/userguide.html
 | 
					bindsym $mod+Shift+slash exec $browser https://i3wm.org/docs/userguide.html
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# no title bars
 | 
					# no title bars
 | 
				
			||||||
for_window [class="^.*"] border pixel 2
 | 
					for_window [class="^.*"] border pixel 1
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# disable mouse hover focus
 | 
					# disable mouse hover focus
 | 
				
			||||||
focus_follows_mouse no
 | 
					focus_follows_mouse no
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# kill focused window
 | 
					# kill focused window
 | 
				
			||||||
bindsym $mod+q kill
 | 
					bindsym $window+q kill
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Toggle focus
 | 
				
			||||||
 | 
					bindsym $window+f floating toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# GTK Themes
 | 
					# GTK Themes
 | 
				
			||||||
exec --no-startup-id gnome-settings-daemon
 | 
					exec --no-startup-id gnome-settings-daemon
 | 
				
			||||||
| 
						 | 
					@ -122,18 +164,14 @@ bindsym $mod+v split vertical
 | 
				
			||||||
# cannot bind $mod+h because of movement commands
 | 
					# cannot bind $mod+h because of movement commands
 | 
				
			||||||
bindsym $mod+Shift+v split horizontal
 | 
					bindsym $mod+Shift+v split horizontal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# lock the screen (Window's famous Ctrl-Alt-Delete)
 | 
					 | 
				
			||||||
bindsym $mod+Ctrl+Delete exec xsecurelock
 | 
					 | 
				
			||||||
bindsym $mod+Shift+q     exec xsecurelock
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# sound applet
 | 
					# sound applet
 | 
				
			||||||
exec --no-startup-id gnome-sound-applet
 | 
					exec --no-startup-id gnome-sound-applet
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# change focus
 | 
					# change focus
 | 
				
			||||||
bindsym $mod+h focus left
 | 
					bindsym $window+h focus left
 | 
				
			||||||
bindsym $mod+j focus down
 | 
					bindsym $window+j focus down
 | 
				
			||||||
bindsym $mod+k focus up
 | 
					bindsym $window+k focus up
 | 
				
			||||||
bindsym $mod+l focus right
 | 
					bindsym $window+l focus right
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# move focused window
 | 
					# move focused window
 | 
				
			||||||
bindsym $mod+Shift+h move left  100
 | 
					bindsym $mod+Shift+h move left  100
 | 
				
			||||||
| 
						 | 
					@ -141,12 +179,8 @@ bindsym $mod+Shift+j move down  100
 | 
				
			||||||
bindsym $mod+Shift+k move up    100
 | 
					bindsym $mod+Shift+k move up    100
 | 
				
			||||||
bindsym $mod+Shift+l move right 100
 | 
					bindsym $mod+Shift+l move right 100
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# enable duplicating the current window vertically or horizontally
 | 
					 | 
				
			||||||
# bindsym $mod+- split v exec terminator
 | 
					 | 
				
			||||||
# bindsym $mod+\ split h exec terminator
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# enter fullscreen mode for the focused container
 | 
					# enter fullscreen mode for the focused container
 | 
				
			||||||
bindsym $mod+z fullscreen toggle
 | 
					bindsym $window+z fullscreen toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# change container layout (stacked, tabbed, toggle split)
 | 
					# change container layout (stacked, tabbed, toggle split)
 | 
				
			||||||
bindsym $super+e layout toggle split
 | 
					bindsym $super+e layout toggle split
 | 
				
			||||||
| 
						 | 
					@ -159,11 +193,8 @@ bindsym $mod+Shift+f floating toggle
 | 
				
			||||||
# toggle stickiness
 | 
					# toggle stickiness
 | 
				
			||||||
bindsym $mod+Shift+s sticky toggle
 | 
					bindsym $mod+Shift+s sticky toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# change focus between tiling / floating windows
 | 
					 | 
				
			||||||
bindsym $mod+f focus mode_toggle
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# focus the parent container
 | 
					# focus the parent container
 | 
				
			||||||
bindsym $mod+a focus parent
 | 
					# bindsym $mod+a focus parent
 | 
				
			||||||
bindsym $mod+Shift+a focus child
 | 
					bindsym $mod+Shift+a focus child
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Define names for default workspaces for which we configure key bindings later on.
 | 
					# Define names for default workspaces for which we configure key bindings later on.
 | 
				
			||||||
| 
						 | 
					@ -191,6 +222,19 @@ bindsym $mod+8 workspace $ws8
 | 
				
			||||||
bindsym $mod+9 workspace $ws9
 | 
					bindsym $mod+9 workspace $ws9
 | 
				
			||||||
bindsym $mod+0 workspace $ws10
 | 
					bindsym $mod+0 workspace $ws10
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# edit configuration files
 | 
				
			||||||
 | 
					# TODO: Standardize KBDs for C,R,U,D operations.
 | 
				
			||||||
 | 
					# TODO: Move shell script to /usr/local/bin
 | 
				
			||||||
 | 
					# Create
 | 
				
			||||||
 | 
					# TODO: Choose another KBD. This is temporary.
 | 
				
			||||||
 | 
					bindsym $mod+a       exec zsh -i -c add_config
 | 
				
			||||||
 | 
					# Read
 | 
				
			||||||
 | 
					bindsym $mod+c       exec zsh -i -c edit_config
 | 
				
			||||||
 | 
					# Update
 | 
				
			||||||
 | 
					# TODO: Support operation to update_config label and path
 | 
				
			||||||
 | 
					# Delete
 | 
				
			||||||
 | 
					bindsym $mod+Shift+c exec zsh -i -c rm_config
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# move and follow focused container to workspace
 | 
					# move and follow focused container to workspace
 | 
				
			||||||
bindsym $mod+Shift+1 move container to workspace $ws1;  workspace $ws1
 | 
					bindsym $mod+Shift+1 move container to workspace $ws1;  workspace $ws1
 | 
				
			||||||
bindsym $mod+Shift+2 move container to workspace $ws2;  workspace $ws2
 | 
					bindsym $mod+Shift+2 move container to workspace $ws2;  workspace $ws2
 | 
				
			||||||
| 
						 | 
					@ -219,6 +263,22 @@ bindsym $mod+Ctrl+0 move container to workspace $ws10
 | 
				
			||||||
bindsym $super+r       exec cat ~/.config/i3/config.shared ~/.config/i3/config.device >~/.config/i3/config; reload
 | 
					bindsym $super+r       exec cat ~/.config/i3/config.shared ~/.config/i3/config.device >~/.config/i3/config; reload
 | 
				
			||||||
bindsym $super+Shift+r exec cat ~/.config/i3/config.shared ~/.config/i3/config.device >~/.config/i3/config; restart
 | 
					bindsym $super+Shift+r exec cat ~/.config/i3/config.shared ~/.config/i3/config.device >~/.config/i3/config; restart
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# logout dialog
 | 
				
			||||||
 | 
					set $mode_system System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown
 | 
				
			||||||
 | 
					mode "$mode_system" {
 | 
				
			||||||
 | 
					    bindsym l       exec --no-startup-id xsecurelock,                        mode "default"
 | 
				
			||||||
 | 
					    bindsym e       exit,                                                    mode "default"
 | 
				
			||||||
 | 
					    bindsym s       exec --no-startup-id xsecurelock && systemctl suspend,   mode "default"
 | 
				
			||||||
 | 
					    bindsym h       exec --no-startup-id xsecurelock && systemctl hibernate, mode "default"
 | 
				
			||||||
 | 
					    bindsym r       exec --no-startup-id systemctl reboot,                   mode "default"
 | 
				
			||||||
 | 
					    bindsym Shift+s exec --no-startup-id systemctl poweroff,                 mode "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    # back to normal: Enter or Escape
 | 
				
			||||||
 | 
					    bindsym Escape mode "default"
 | 
				
			||||||
 | 
					    bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					    bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym Ctrl+Mod1+Delete mode "$mode_system"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# resize window (you can also use the mouse for that)
 | 
					# resize window (you can also use the mouse for that)
 | 
				
			||||||
mode "resize" {
 | 
					mode "resize" {
 | 
				
			||||||
| 
						 | 
					@ -226,9 +286,10 @@ mode "resize" {
 | 
				
			||||||
        bindsym j resize shrink height 10 px or 10 ppt
 | 
					        bindsym j resize shrink height 10 px or 10 ppt
 | 
				
			||||||
        bindsym k resize grow   height 10 px or 10 ppt
 | 
					        bindsym k resize grow   height 10 px or 10 ppt
 | 
				
			||||||
        bindsym l resize grow   width  10 px or 10 ppt
 | 
					        bindsym l resize grow   width  10 px or 10 ppt
 | 
				
			||||||
        bindsym Return       mode "default"
 | 
					
 | 
				
			||||||
        bindsym Caps_Lock    mode "default"
 | 
					        bindsym Escape mode "default"
 | 
				
			||||||
        bindsym $mod+Shift+r mode "default"
 | 
					        bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					        bindsym Ctrl+c mode "default"
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
bindsym $mod+Shift+r mode "resize"
 | 
					bindsym $mod+Shift+r mode "resize"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -238,42 +299,31 @@ mode "passthrough" {
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
bindsym $mod+Escape mode "passthrough"
 | 
					bindsym $mod+Escape mode "passthrough"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Atom One Dark colors
 | 
					# class                 border     backgr     text      indicator child_border
 | 
				
			||||||
set $black          #1e2127
 | 
					client.focused          #83526a   #83526a   #8de0e1 #E8C35F  #83526a
 | 
				
			||||||
set $red            #e06c75
 | 
					client.focused_inactive #83526a   #83526a   #8de0e1 #E8C35F  #5a3849
 | 
				
			||||||
set $green          #98c379
 | 
					client.unfocused        #5a3849 #5a3849 #8de0e1 #E8C35F  #5a3849
 | 
				
			||||||
set $yellow         #d19a66
 | 
					client.urgent           #E8C35F   #E8C35F   #8de0e1 #E8C35F  #E8C35F
 | 
				
			||||||
set $blue           #61afef
 | 
					client.placeholder      #31213f   #629c9d   #8de0e1 #31213f  #629c9d
 | 
				
			||||||
set $magenta        #c678dd
 | 
					client.background       #31213f
 | 
				
			||||||
set $cyan           #56b6c2
 | 
					 | 
				
			||||||
set $white          #abb2bf
 | 
					 | 
				
			||||||
set $bright_black   #5c6370
 | 
					 | 
				
			||||||
set $bright_red     #e06c75
 | 
					 | 
				
			||||||
set $bright_green   #98c379
 | 
					 | 
				
			||||||
set $bright_yellow  #d19a66
 | 
					 | 
				
			||||||
set $bright_white   #ffffff
 | 
					 | 
				
			||||||
set $bright_blue    #61afef
 | 
					 | 
				
			||||||
set $bright_magenta #c678dd
 | 
					 | 
				
			||||||
set $bright_cyan    #56b6c2
 | 
					 | 
				
			||||||
set $selection      #3a3f4b
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# class                 # border    # bg # text #indicator #child_border
 | 
					 | 
				
			||||||
client.focused          $red        $red $red   $magenta   $bright_cyan
 | 
					 | 
				
			||||||
client.focused_inactive $red        $red $red   $magenta   $black
 | 
					 | 
				
			||||||
client.unfocused        $red        $red $red   $magenta   $black
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
bar {
 | 
					bar {
 | 
				
			||||||
    status_command i3status
 | 
					    status_command i3status
 | 
				
			||||||
 | 
					    font pango:Monospace 10px
 | 
				
			||||||
    position top
 | 
					    position top
 | 
				
			||||||
    # disable system tray icons
 | 
					    # disable system tray icons
 | 
				
			||||||
    tray_output none
 | 
					    tray_output none
 | 
				
			||||||
    colors {
 | 
					    colors {
 | 
				
			||||||
           background $black
 | 
					           background #31213f
 | 
				
			||||||
           statusline $white
 | 
					           statusline #83526a # text color in status line
 | 
				
			||||||
           separator  $yellow
 | 
					           separator  #83526a
 | 
				
			||||||
           focused_workspace  $black $black $bright_cyan
 | 
					           # class            border     text       indicator
 | 
				
			||||||
           active_workspace   $red $bright_blue $blue
 | 
					           focused_workspace  #83526a   #8de0e1  #31213f
 | 
				
			||||||
           inactive_workspace $black $black $bright_black
 | 
					           active_workspace   #83526a   #5a3849 #83526a
 | 
				
			||||||
           urgent_workspace   $magenta $black $magenta
 | 
					           inactive_workspace #5a3849 #83526a   #5a3849
 | 
				
			||||||
 | 
					           urgent_workspace   #5a3849 #83526a   #5a3849
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# wpg integration
 | 
				
			||||||
 | 
					exec --no-startup-id ~/.config/wpg/wp_init.sh
 | 
				
			||||||
							
								
								
									
										330
									
								
								configs/shared/.config/i3/config.bak
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										330
									
								
								configs/shared/.config/i3/config.bak
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,330 @@
 | 
				
			||||||
 | 
					# Keymapping philosophy:
 | 
				
			||||||
 | 
					# When I feel it's appropriate, I try to borrow existing KBDs from OSX or
 | 
				
			||||||
 | 
					# Windows. For example, I use Ctrl+Alt+Del to start the screen lock, since this
 | 
				
			||||||
 | 
					# is a really well-known KBD. One notable difference is that when I'm borrowing
 | 
				
			||||||
 | 
					# OSX KBDs, I prefer using Alt instead of Super since the keyboard that I'm
 | 
				
			||||||
 | 
					# using has the Alt key in the same location as the Super key on my mac
 | 
				
			||||||
 | 
					# keyboard. I could rebind this, and I just may. But for now, that's worth
 | 
				
			||||||
 | 
					# pointing out.
 | 
				
			||||||
 | 
					# The reason behind borrowing from Windows and OSX is that some of these
 | 
				
			||||||
 | 
					# keybindings are hardwired into my muscle memory. I also tend to work between
 | 
				
			||||||
 | 
					# Linux and OSX quite often. Since OSX is much more difficult to remap KBDs
 | 
				
			||||||
 | 
					# than it is in Linux, I prefer to support the OSX KBDs to reduce the number of
 | 
				
			||||||
 | 
					# KBDs my feeble memory needs to store.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					set $mod Mod1
 | 
				
			||||||
 | 
					set $window Mod1+Ctrl
 | 
				
			||||||
 | 
					set $super Mod4
 | 
				
			||||||
 | 
					# TODO: Support alacritty or another fast terminal.
 | 
				
			||||||
 | 
					set $terminal terminator
 | 
				
			||||||
 | 
					set $browser  google-chrome
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Font for window titles. Will also be used by the bar unless a different font
 | 
				
			||||||
 | 
					# is used in the bar block below.
 | 
				
			||||||
 | 
					font pango:Monospace 10px
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Use Mouse+$mod to drag floating windows to their wanted position
 | 
				
			||||||
 | 
					floating_modifier $mod
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# i3-gaps (depends on i3-gaps installation)
 | 
				
			||||||
 | 
					# gaps inner 7
 | 
				
			||||||
 | 
					# gaps outer 0
 | 
				
			||||||
 | 
					# smart_gaps on
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# bindsym $mod+Ctrl+plus   gaps outer current plus  5
 | 
				
			||||||
 | 
					# bindsym $mod+Ctrl+minus  gaps outer current minus 5
 | 
				
			||||||
 | 
					# bindsym $mod+Shift+plus  gaps inner current plus  5
 | 
				
			||||||
 | 
					# bindsym $mod+Shift+minus gaps inner current minus 5
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Support XF86 keys for audio playback and volume control
 | 
				
			||||||
 | 
					bindsym XF86AudioMute        exec --no-startup-id pactl set-sink-mute   @DEFAULT_SINK@ toggle
 | 
				
			||||||
 | 
					bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10%
 | 
				
			||||||
 | 
					bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10%
 | 
				
			||||||
 | 
					bindsym XF86AudioPrev        exec --no-startup-id playerctl previous
 | 
				
			||||||
 | 
					bindsym XF86AudioNext        exec --no-startup-id playerctl next
 | 
				
			||||||
 | 
					bindsym XF86AudioStop        exec --no-startup-id playerctl play-pause
 | 
				
			||||||
 | 
					bindsym XF86AudioPlay        exec --no-startup-id playerctl play-pause
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# KBD Principles:
 | 
				
			||||||
 | 
					# $mod+Ctrl+<app_char>       = starting an application
 | 
				
			||||||
 | 
					# where <app_char> is a reserved character for a commonly used application.
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# <app_char> definitions:
 | 
				
			||||||
 | 
					# terminal = t, Return
 | 
				
			||||||
 | 
					# emacs    = e
 | 
				
			||||||
 | 
					# chrome   = c
 | 
				
			||||||
 | 
					# spotify  = s
 | 
				
			||||||
 | 
					# intellij = i
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+t exec $terminal
 | 
				
			||||||
 | 
					bindsym $mod+Return exec $terminal
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+e exec emacsclient --create-frame
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+c exec $browser
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+s exec spotify
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+i exec zsh -i -c intellij
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# support dmenu-based bookmarks
 | 
				
			||||||
 | 
					# bindsym $mod+Ctrl+b exec rofi -dmenu <$DOTFILES/bookmarks.txt | xargs $browser
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					set $bookmarks_mode Bookmarks (a) add, (d) delete, (b) browse
 | 
				
			||||||
 | 
					mode "$bookmarks_mode" {
 | 
				
			||||||
 | 
					     bindsym a exec zsh -i -c add_bookmark,  mode "default"
 | 
				
			||||||
 | 
					     bindsym d exec zsh -i -c rm_bookmark,   mode "default"
 | 
				
			||||||
 | 
					     bindsym b exec zsh -i -c open_bookmark, mode "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					     bindsym Escape mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+b mode "$bookmarks_mode"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# pass integration
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+backslash exec ~/.config/i3/passmenu # mirroring the 1password KBD
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# integrate with Emacs's org-mode
 | 
				
			||||||
 | 
					bindsym $mod+o exec zsh -i -c org_capture
 | 
				
			||||||
 | 
					# TODO: Support "coding size", "dialog-size" (for org_capture)
 | 
				
			||||||
 | 
					# TODO: Support way to cycle through predefined sizes.
 | 
				
			||||||
 | 
					for_window [class="GoogleEmacs" instance="floating"] floating enable, resize set height 1200px, resize set width 780px
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Here is a sketch of the cycle sizes idea.
 | 
				
			||||||
 | 
					# TODO: Support this.
 | 
				
			||||||
 | 
					# mode "cycle_sizes_floating_mode" {
 | 
				
			||||||
 | 
					#      # coding mode
 | 
				
			||||||
 | 
					#      bindsym a for_window [mode="floating", class="actively-selected"] resize set height 1200px, resize set width 780px
 | 
				
			||||||
 | 
					#      bindsym b for_window [mode="floating", class="actively-selected"] resize set height 500px, resize set width 500px
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					#      bindsym Escape mode "default"
 | 
				
			||||||
 | 
					#      bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					#      bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					# }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# ensure Spotify windows float
 | 
				
			||||||
 | 
					for_window [class="Spotify"] floating enable
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# ensure system service that run through XDG start
 | 
				
			||||||
 | 
					exec --no-startup-id dex -ae i3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# rofi configuration
 | 
				
			||||||
 | 
					bindsym $mod+space exec --no-startup-id rofi -show combi
 | 
				
			||||||
 | 
					bindsym $mod+t     exec --no-startup-id ~/.config/i3/dmenu_timer.sh ~/.local/share/sounds/gong.mp3
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# switch workspaces
 | 
				
			||||||
 | 
					bindsym $mod+Tab       workspace next
 | 
				
			||||||
 | 
					bindsym $mod+Shift+Tab workspace prev
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# file manager
 | 
				
			||||||
 | 
					bindsym $mod+n exec $terminal -x lf ~/Dropbox
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# clipboard manager
 | 
				
			||||||
 | 
					# NOTE: Ctrl-c is already covered since `clipmenu` listens for X clipboard
 | 
				
			||||||
 | 
					# events using `clipnotify`.
 | 
				
			||||||
 | 
					# NOTE: `clipmenud` is started in `.xsessionrc.shared`
 | 
				
			||||||
 | 
					# NOTE: This is a bit of a hack intended to support pasting in both the terminal
 | 
				
			||||||
 | 
					# and in GUI applications. `st` expects `ctrl+Shift+v` while GUIs expect
 | 
				
			||||||
 | 
					# `ctrl+v`. In the instances where GUIs don't support `ctrl+Shift+v` already, it
 | 
				
			||||||
 | 
					# acts like `ctrl+v`, so it should "just work".
 | 
				
			||||||
 | 
					bindsym Ctrl+$mod+v exec clipmenu && xdotool key --clearmodifiers ctrl+Shift+v
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Screenshot
 | 
				
			||||||
 | 
					# TODO: Support variants: (a) App (r) Region (f) Fullscreen.
 | 
				
			||||||
 | 
					# TODO: Support hosting to third-party image hosting.
 | 
				
			||||||
 | 
					set $screenshot_mode Screenshot (g) googleplex (l) local
 | 
				
			||||||
 | 
					mode "$screenshot_mode" {
 | 
				
			||||||
 | 
					     bindsym g exec zsh -i -c snipit,     mode "default"
 | 
				
			||||||
 | 
					     bindsym l exec zsh -i -c screenshot, mode "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					     bindsym Escape mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					     bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym $mod+s mode "$screenshot_mode"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# online documentation
 | 
				
			||||||
 | 
					bindsym $mod+Shift+slash exec $browser https://i3wm.org/docs/userguide.html
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# no title bars
 | 
				
			||||||
 | 
					for_window [class="^.*"] border pixel 1
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# disable mouse hover focus
 | 
				
			||||||
 | 
					focus_follows_mouse no
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# kill focused window
 | 
				
			||||||
 | 
					bindsym $window+q kill
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Toggle focus
 | 
				
			||||||
 | 
					bindsym $window+f floating toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# GTK Themes
 | 
				
			||||||
 | 
					exec --no-startup-id gnome-settings-daemon
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# wireless selection mechanism
 | 
				
			||||||
 | 
					exec --no-startup-id nm-applet
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# set the split direction
 | 
				
			||||||
 | 
					bindsym $mod+v split vertical
 | 
				
			||||||
 | 
					# cannot bind $mod+h because of movement commands
 | 
				
			||||||
 | 
					bindsym $mod+Shift+v split horizontal
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# sound applet
 | 
				
			||||||
 | 
					exec --no-startup-id gnome-sound-applet
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# change focus
 | 
				
			||||||
 | 
					bindsym $window+h focus left
 | 
				
			||||||
 | 
					bindsym $window+j focus down
 | 
				
			||||||
 | 
					bindsym $window+k focus up
 | 
				
			||||||
 | 
					bindsym $window+l focus right
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# move focused window
 | 
				
			||||||
 | 
					bindsym $mod+Shift+h move left  100
 | 
				
			||||||
 | 
					bindsym $mod+Shift+j move down  100
 | 
				
			||||||
 | 
					bindsym $mod+Shift+k move up    100
 | 
				
			||||||
 | 
					bindsym $mod+Shift+l move right 100
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# enter fullscreen mode for the focused container
 | 
				
			||||||
 | 
					bindsym $window+z fullscreen toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# change container layout (stacked, tabbed, toggle split)
 | 
				
			||||||
 | 
					bindsym $super+e layout toggle split
 | 
				
			||||||
 | 
					bindsym $super+s layout stacking
 | 
				
			||||||
 | 
					bindsym $super+t layout tabbed
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# toggle tiling / floating
 | 
				
			||||||
 | 
					bindsym $mod+Shift+f floating toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# toggle stickiness
 | 
				
			||||||
 | 
					bindsym $mod+Shift+s sticky toggle
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# focus the parent container
 | 
				
			||||||
 | 
					# bindsym $mod+a focus parent
 | 
				
			||||||
 | 
					bindsym $mod+Shift+a focus child
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# 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"
 | 
				
			||||||
 | 
					set $ws2  "2"
 | 
				
			||||||
 | 
					set $ws3  "3"
 | 
				
			||||||
 | 
					set $ws4  "4"
 | 
				
			||||||
 | 
					set $ws5  "5"
 | 
				
			||||||
 | 
					set $ws6  "6"
 | 
				
			||||||
 | 
					set $ws7  "7"
 | 
				
			||||||
 | 
					set $ws8  "8"
 | 
				
			||||||
 | 
					set $ws9  "9"
 | 
				
			||||||
 | 
					set $ws10 "10"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# jump to workspace
 | 
				
			||||||
 | 
					bindsym $mod+1 workspace $ws1
 | 
				
			||||||
 | 
					bindsym $mod+2 workspace $ws2
 | 
				
			||||||
 | 
					bindsym $mod+3 workspace $ws3
 | 
				
			||||||
 | 
					bindsym $mod+4 workspace $ws4
 | 
				
			||||||
 | 
					bindsym $mod+5 workspace $ws5
 | 
				
			||||||
 | 
					bindsym $mod+6 workspace $ws6
 | 
				
			||||||
 | 
					bindsym $mod+7 workspace $ws7
 | 
				
			||||||
 | 
					bindsym $mod+8 workspace $ws8
 | 
				
			||||||
 | 
					bindsym $mod+9 workspace $ws9
 | 
				
			||||||
 | 
					bindsym $mod+0 workspace $ws10
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# edit configuration files
 | 
				
			||||||
 | 
					# TODO: Standardize KBDs for C,R,U,D operations.
 | 
				
			||||||
 | 
					# TODO: Move shell script to /usr/local/bin
 | 
				
			||||||
 | 
					# Create
 | 
				
			||||||
 | 
					# TODO: Choose another KBD. This is temporary.
 | 
				
			||||||
 | 
					bindsym $mod+a       exec zsh -i -c add_config
 | 
				
			||||||
 | 
					# Read
 | 
				
			||||||
 | 
					bindsym $mod+c       exec zsh -i -c edit_config
 | 
				
			||||||
 | 
					# Update
 | 
				
			||||||
 | 
					# TODO: Support operation to update_config label and path
 | 
				
			||||||
 | 
					# Delete
 | 
				
			||||||
 | 
					bindsym $mod+Shift+c exec zsh -i -c rm_config
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# move and follow focused container to workspace
 | 
				
			||||||
 | 
					bindsym $mod+Shift+1 move container to workspace $ws1;  workspace $ws1
 | 
				
			||||||
 | 
					bindsym $mod+Shift+2 move container to workspace $ws2;  workspace $ws2
 | 
				
			||||||
 | 
					bindsym $mod+Shift+3 move container to workspace $ws3;  workspace $ws3
 | 
				
			||||||
 | 
					bindsym $mod+Shift+4 move container to workspace $ws4;  workspace $ws4
 | 
				
			||||||
 | 
					bindsym $mod+Shift+5 move container to workspace $ws5;  workspace $ws5
 | 
				
			||||||
 | 
					bindsym $mod+Shift+6 move container to workspace $ws6;  workspace $ws6
 | 
				
			||||||
 | 
					bindsym $mod+Shift+7 move container to workspace $ws7;  workspace $ws7
 | 
				
			||||||
 | 
					bindsym $mod+Shift+8 move container to workspace $ws8;  workspace $ws8
 | 
				
			||||||
 | 
					bindsym $mod+Shift+9 move container to workspace $ws9;  workspace $ws9
 | 
				
			||||||
 | 
					bindsym $mod+Shift+0 move container to workspace $ws10; workspace $ws10
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# move focused container to workspace
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+1 move container to workspace $ws1
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+2 move container to workspace $ws2
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+3 move container to workspace $ws3
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+4 move container to workspace $ws4
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+5 move container to workspace $ws5
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+6 move container to workspace $ws6
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+7 move container to workspace $ws7
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+8 move container to workspace $ws8
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+9 move container to workspace $ws9
 | 
				
			||||||
 | 
					bindsym $mod+Ctrl+0 move container to workspace $ws10
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# reload, restart i3
 | 
				
			||||||
 | 
					bindsym $super+r       exec cat ~/.config/i3/config.shared ~/.config/i3/config.device >~/.config/i3/config; reload
 | 
				
			||||||
 | 
					bindsym $super+Shift+r exec cat ~/.config/i3/config.shared ~/.config/i3/config.device >~/.config/i3/config; restart
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# logout dialog
 | 
				
			||||||
 | 
					set $mode_system System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown
 | 
				
			||||||
 | 
					mode "$mode_system" {
 | 
				
			||||||
 | 
					    bindsym l       exec --no-startup-id xsecurelock,                        mode "default"
 | 
				
			||||||
 | 
					    bindsym e       exit,                                                    mode "default"
 | 
				
			||||||
 | 
					    bindsym s       exec --no-startup-id xsecurelock && systemctl suspend,   mode "default"
 | 
				
			||||||
 | 
					    bindsym h       exec --no-startup-id xsecurelock && systemctl hibernate, mode "default"
 | 
				
			||||||
 | 
					    bindsym r       exec --no-startup-id systemctl reboot,                   mode "default"
 | 
				
			||||||
 | 
					    bindsym Shift+s exec --no-startup-id systemctl poweroff,                 mode "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    # back to normal: Enter or Escape
 | 
				
			||||||
 | 
					    bindsym Escape mode "default"
 | 
				
			||||||
 | 
					    bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					    bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym Ctrl+Mod1+Delete mode "$mode_system"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# resize window (you can also use the mouse for that)
 | 
				
			||||||
 | 
					mode "resize" {
 | 
				
			||||||
 | 
					        bindsym h resize shrink width  10 px or 10 ppt
 | 
				
			||||||
 | 
					        bindsym j resize shrink height 10 px or 10 ppt
 | 
				
			||||||
 | 
					        bindsym k resize grow   height 10 px or 10 ppt
 | 
				
			||||||
 | 
					        bindsym l resize grow   width  10 px or 10 ppt
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        bindsym Escape mode "default"
 | 
				
			||||||
 | 
					        bindsym Ctrl+g mode "default"
 | 
				
			||||||
 | 
					        bindsym Ctrl+c mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym $mod+Shift+r mode "resize"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# passthrough mode to support Emacs, Tmux, Vim KBDs for window and pane management
 | 
				
			||||||
 | 
					mode "passthrough" {
 | 
				
			||||||
 | 
					     bindsym $mod+Escape mode "default"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					bindsym $mod+Escape mode "passthrough"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# class                 border     backgr     text      indicator child_border
 | 
				
			||||||
 | 
					# client.focused          {active}   {active}   {color15} {color2}  {active}
 | 
				
			||||||
 | 
					# client.focused_inactive {active}   {active}   {color15} {color2}  {inactive}
 | 
				
			||||||
 | 
					# client.unfocused        {inactive} {inactive} {color15} {color2}  {inactive}
 | 
				
			||||||
 | 
					# client.urgent           {color2}   {color2}   {color15} {color2}  {color2}
 | 
				
			||||||
 | 
					# client.placeholder      {color0}   {color8}   {color15} {color0}  {color8}
 | 
				
			||||||
 | 
					# client.background       {color0}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					bar {
 | 
				
			||||||
 | 
					    status_command i3status
 | 
				
			||||||
 | 
					    font pango:Monospace 10px
 | 
				
			||||||
 | 
					    position top
 | 
				
			||||||
 | 
					    # disable system tray icons
 | 
				
			||||||
 | 
					    tray_output none
 | 
				
			||||||
 | 
					    colors {
 | 
				
			||||||
 | 
					           # background {color0}
 | 
				
			||||||
 | 
					           # statusline {inactive}
 | 
				
			||||||
 | 
					           # separator  {active}
 | 
				
			||||||
 | 
					           # class            border     text       indicator
 | 
				
			||||||
 | 
					           # focused_workspace  {active}   {color15}  {color0}
 | 
				
			||||||
 | 
					           # active_workspace   {active}   {inactive} {active}
 | 
				
			||||||
 | 
					           # inactive_workspace {inactive} {active}   {inactive}
 | 
				
			||||||
 | 
					           # urgent_workspace   {inactive} {active}   {inactive}
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# wpg integration
 | 
				
			||||||
 | 
					exec --no-startup-id ~/.config/wpg/wp_init.sh
 | 
				
			||||||
							
								
								
									
										58
									
								
								configs/shared/.config/i3status/config
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										58
									
								
								configs/shared/.config/i3status/config
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,58 @@
 | 
				
			||||||
 | 
					general {
 | 
				
			||||||
 | 
					  markup = pango
 | 
				
			||||||
 | 
					  separator = " "
 | 
				
			||||||
 | 
					  colors = true
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					/* order += "battery 0" # TODO: remove this if "battery 1" works for Dell */
 | 
				
			||||||
 | 
					order += "battery 1" # trying to support two different laptops
 | 
				
			||||||
 | 
					order += "tztime local"
 | 
				
			||||||
 | 
					order += "tztime lon"
 | 
				
			||||||
 | 
					order += "tztime est"
 | 
				
			||||||
 | 
					order += "tztime pst"
 | 
				
			||||||
 | 
					order += "disk /"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					disk "/" {
 | 
				
			||||||
 | 
					  prefix_type = "decimal"
 | 
				
			||||||
 | 
					  format = "%used/%total"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Useful commands for dealing with timezones:
 | 
				
			||||||
 | 
					# - cat /etc/timezone
 | 
				
			||||||
 | 
					# - man date
 | 
				
			||||||
 | 
					# - timedatectl
 | 
				
			||||||
 | 
					tztime local {
 | 
				
			||||||
 | 
					  format = "%d/%m/%Y"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					tztime lon {
 | 
				
			||||||
 | 
					  format = "LON %H:%M"
 | 
				
			||||||
 | 
					  timezone = "Europe/London"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					tztime est {
 | 
				
			||||||
 | 
					  format = "NYC %H:%M"
 | 
				
			||||||
 | 
					  timezone = "US/Eastern"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					tztime pst {
 | 
				
			||||||
 | 
					  format = "MTV %H:%M"
 | 
				
			||||||
 | 
					  timezone = "US/Pacific"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# TODO: remove this if "battery 1" works for Dell laptop
 | 
				
			||||||
 | 
					/* battery 0 { */
 | 
				
			||||||
 | 
					/*   format = "Battery %percentage" */
 | 
				
			||||||
 | 
					/*   format_down = "" # This hides the battery when there isn't any (e.g. on a Desktop) */
 | 
				
			||||||
 | 
					/*   low_threshold = 30 */
 | 
				
			||||||
 | 
					/*   threshold_type = time */
 | 
				
			||||||
 | 
					/*   integer_battery_capacity = true */
 | 
				
			||||||
 | 
					/* } */
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					battery 1 {
 | 
				
			||||||
 | 
					  format = "Battery %percentage"
 | 
				
			||||||
 | 
					  format_down = "" # This hides the battery when there isn't any (e.g. on a Desktop)
 | 
				
			||||||
 | 
					  low_threshold = 30
 | 
				
			||||||
 | 
					  threshold_type = time
 | 
				
			||||||
 | 
					  integer_battery_capacity = true
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
| 
						 | 
					@ -48,6 +48,9 @@
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Basic configuration
 | 
					# Basic configuration
 | 
				
			||||||
set hidden on
 | 
					set hidden on
 | 
				
			||||||
 | 
					set info size:time
 | 
				
			||||||
 | 
					set sortby time
 | 
				
			||||||
 | 
					set period 1 # auto-refreshes the view
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Arguably the most import function herein
 | 
					# Arguably the most import function herein
 | 
				
			||||||
cmd help $lf -doc | less
 | 
					cmd help $lf -doc | less
 | 
				
			||||||
| 
						 | 
					@ -55,18 +58,15 @@ cmd help $lf -doc | less
 | 
				
			||||||
# delete a file, dir
 | 
					# delete a file, dir
 | 
				
			||||||
map D delete
 | 
					map D delete
 | 
				
			||||||
 | 
					
 | 
				
			||||||
cmd rename %{{
 | 
					# reload the view
 | 
				
			||||||
    # Renames files, dirs.
 | 
					map r load
 | 
				
			||||||
    set -f
 | 
					
 | 
				
			||||||
    if [ -e "$1" ]; then
 | 
					# rename files
 | 
				
			||||||
      printf 'file exists'
 | 
					cmd rename %[ -e $1 ] && printf 'file exists' || mv $f $1
 | 
				
			||||||
    else
 | 
					 | 
				
			||||||
      mv "$f" "$1"
 | 
					 | 
				
			||||||
    fi
 | 
					 | 
				
			||||||
}}
 | 
					 | 
				
			||||||
map R push :rename<space>
 | 
					map R push :rename<space>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
cmd mkdir %{{
 | 
					cmd mkdir %{{
 | 
				
			||||||
 | 
					    # mkdir and cd into that dir
 | 
				
			||||||
    mkdir -p "$1"
 | 
					    mkdir -p "$1"
 | 
				
			||||||
}}
 | 
					}}
 | 
				
			||||||
map + push :mkdir<space>
 | 
					map + push :mkdir<space>
 | 
				
			||||||
| 
						 | 
					@ -75,31 +75,19 @@ cmd touch %{{
 | 
				
			||||||
    # Create a file
 | 
					    # Create a file
 | 
				
			||||||
    touch "$1"
 | 
					    touch "$1"
 | 
				
			||||||
}}
 | 
					}}
 | 
				
			||||||
map c push :touch<space>
 | 
					map c push :touch<space> # this interferes with `clear` command
 | 
				
			||||||
 | 
					
 | 
				
			||||||
cmd encrypt_file %{{
 | 
					cmd encrypt %{{
 | 
				
			||||||
  # Encrypts the file and deletes the cleartext version.
 | 
					  # depends on my shell function, encrypt
 | 
				
			||||||
  # Run `decrypt_file` to return the file to its cleartext version.
 | 
					  zsh -i -c "encrypt $f"
 | 
				
			||||||
  printf "recipient: "
 | 
					 | 
				
			||||||
  read recipient
 | 
					 | 
				
			||||||
  gpg --encrypt --recipient "$recipient" "$f" && rm "$f"
 | 
					 | 
				
			||||||
}}
 | 
					}}
 | 
				
			||||||
map xe :encrypt_file
 | 
					map xe :encrypt
 | 
				
			||||||
 | 
					
 | 
				
			||||||
cmd decrypt_file %{{
 | 
					cmd decrypt %{{
 | 
				
			||||||
  # Decrypts a file that was encrypted with `encrypt_file`.
 | 
					  # depends on my shell function, decrypt
 | 
				
			||||||
  # Assumes encrypted files have the .gpg extension and decrypted files omit the
 | 
					  zsh -i -c "decrypt $f"
 | 
				
			||||||
  # .gpg extension.
 | 
					 | 
				
			||||||
  # Deletes the original .gpg file when finished.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
  # check if file exists without .gpg extension
 | 
					 | 
				
			||||||
  if [ -e "${f%.gpg}" ]; then
 | 
					 | 
				
			||||||
    printf "${f%.gpg} exists. Consider deleting or renaming it. Aborting..."
 | 
					 | 
				
			||||||
  else
 | 
					 | 
				
			||||||
    gpg --decrypt "$f" >"${f%.gpg}" 2>/dev/null && rm "$f"
 | 
					 | 
				
			||||||
  fi
 | 
					 | 
				
			||||||
}}
 | 
					}}
 | 
				
			||||||
map xE :decrypt_file
 | 
					map xE :decrypt
 | 
				
			||||||
 | 
					
 | 
				
			||||||
cmd archive %{{
 | 
					cmd archive %{{
 | 
				
			||||||
    # Generic function for archiving directories.
 | 
					    # Generic function for archiving directories.
 | 
				
			||||||
							
								
								
									
										7
									
								
								configs/shared/.config/lf/marks
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								configs/shared/.config/lf/marks
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,7 @@
 | 
				
			||||||
 | 
					':/usr/local/google/home/wpcarro/Dropbox/programming/i3-quickterm
 | 
				
			||||||
 | 
					D:~/Dropbox
 | 
				
			||||||
 | 
					G:/usr/local/google/home/wpcarro/Downloads
 | 
				
			||||||
 | 
					M:/usr/local/google/home/wpcarro/Downloads
 | 
				
			||||||
 | 
					c:~/Dropbox/dotfiles/configs
 | 
				
			||||||
 | 
					d:~/Dropbox/dotfiles
 | 
				
			||||||
 | 
					s:~/Pictures/screenshots
 | 
				
			||||||
							
								
								
									
										
											BIN
										
									
								
								configs/shared/.config/mpd/database
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										
											BIN
										
									
								
								configs/shared/.config/mpd/database
									
										
									
									
									
										Normal file
									
								
							
										
											Binary file not shown.
										
									
								
							
							
								
								
									
										4
									
								
								configs/shared/.config/mpd/mpd.conf
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								configs/shared/.config/mpd/mpd.conf
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,4 @@
 | 
				
			||||||
 | 
					db_file "~/.config/mpd/database"
 | 
				
			||||||
 | 
					log_file "syslog"
 | 
				
			||||||
 | 
					# music_directory "~/.local/share/sounds"
 | 
				
			||||||
 | 
					auto_update "yes"
 | 
				
			||||||
							
								
								
									
										3
									
								
								configs/shared/.config/nixpkgs/config.nix
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								configs/shared/.config/nixpkgs/config.nix
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,3 @@
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					  allowUnfree = true;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
| 
						 | 
					@ -13,6 +13,18 @@ call vundle#begin()
 | 
				
			||||||
" let Vundle manage Vundle, required
 | 
					" let Vundle manage Vundle, required
 | 
				
			||||||
Plugin 'VundleVim/Vundle.vim'
 | 
					Plugin 'VundleVim/Vundle.vim'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Rust IDE features
 | 
				
			||||||
 | 
					Plugin 'racer-rust/vim-racer'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					set hidden
 | 
				
			||||||
 | 
					let g:racer_experimental_completer = 1
 | 
				
			||||||
 | 
					autocmd FileType rust nmap         gd <Plug>(rust-def)
 | 
				
			||||||
 | 
					autocmd FileType rust nmap         gs <Plug>(rust-def-split)
 | 
				
			||||||
 | 
					autocmd FileType rust nmap         gx <Plug>(rust-def-vertical)
 | 
				
			||||||
 | 
					autocmd FileType rust nmap <leader>gd <Plug>(rust-doc)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					Plugin 'xolox/vim-misc'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" The following are examples of different formats supported.
 | 
					" The following are examples of different formats supported.
 | 
				
			||||||
" Keep Plugin commands between vundle#begin/end.
 | 
					" Keep Plugin commands between vundle#begin/end.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -31,27 +43,13 @@ Plugin 'kien/ctrlp.vim'
 | 
				
			||||||
" Grep file contents
 | 
					" Grep file contents
 | 
				
			||||||
Plugin 'mileszs/ack.vim'
 | 
					Plugin 'mileszs/ack.vim'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" JS support
 | 
					" Syntax and other light-weight suppor for a variety of languages
 | 
				
			||||||
Plugin 'pangloss/vim-javascript'
 | 
					Plugin 'sheerun/vim-polyglot'
 | 
				
			||||||
 | 
					 | 
				
			||||||
" JSX support
 | 
					 | 
				
			||||||
Plugin 'mxw/vim-jsx'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Syntax Highlighting Support
 | 
					 | 
				
			||||||
Plugin 'lambdatoast/elm.vim'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Elixir Plugins
 | 
					 | 
				
			||||||
Plugin 'elixir-lang/vim-elixir'
 | 
					 | 
				
			||||||
Plugin 'slashmili/alchemist.vim'
 | 
					 | 
				
			||||||
Plugin 'powerman/vim-plugin-AnsiEsc'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" TypeScript Plugins
 | 
					 | 
				
			||||||
Plugin 'rschmukler/typescript-vim'
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Themes
 | 
					" Themes
 | 
				
			||||||
Plugin 'sickill/vim-monokai'
 | 
					Plugin 'deviantfero/wpgtk.vim'
 | 
				
			||||||
Plugin 'altercation/vim-colors-solarized'
 | 
					Plugin 'rainglow/vim'
 | 
				
			||||||
Plugin 'mhartington/oceanic-next'
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Executes shell commands and pipes output into new Vim buffer.
 | 
					" Executes shell commands and pipes output into new Vim buffer.
 | 
				
			||||||
Plugin 'sjl/clam.vim'
 | 
					Plugin 'sjl/clam.vim'
 | 
				
			||||||
| 
						 | 
					@ -91,9 +89,6 @@ Plugin 'christoomey/vim-tmux-navigator'
 | 
				
			||||||
" Async `:make` for code linting etc.
 | 
					" Async `:make` for code linting etc.
 | 
				
			||||||
Plugin 'neomake/neomake'
 | 
					Plugin 'neomake/neomake'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Color pack
 | 
					 | 
				
			||||||
Plugin 'flazz/vim-colorschemes'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Better buffer mgt than CtrlP
 | 
					" Better buffer mgt than CtrlP
 | 
				
			||||||
Plugin 'yegappan/mru'
 | 
					Plugin 'yegappan/mru'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -102,32 +97,20 @@ Plugin 'zanglg/nova.vim'
 | 
				
			||||||
" Emulates Emacs's Helm Swoop search
 | 
					" Emulates Emacs's Helm Swoop search
 | 
				
			||||||
Plugin 'pelodelfuego/vim-swoop'
 | 
					Plugin 'pelodelfuego/vim-swoop'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Fish Shell support
 | 
					 | 
				
			||||||
Plugin 'dag/vim-fish'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Gotham colorscheme
 | 
					 | 
				
			||||||
Plugin 'whatyouhide/vim-gotham'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Transparent encryption + decryption
 | 
					" Transparent encryption + decryption
 | 
				
			||||||
Plugin 'jamessan/vim-gnupg'
 | 
					Plugin 'jamessan/vim-gnupg'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Javascript auto-formatting
 | 
					" Javascript auto-formatting
 | 
				
			||||||
Plugin 'prettier/vim-prettier', {
 | 
					" Plugin 'prettier/vim-prettier', {
 | 
				
			||||||
  \ 'do': 'yarn install',
 | 
					"   \ 'do': 'yarn install',
 | 
				
			||||||
  \ 'for': ['javascript', 'typescript', 'css', 'less', 'scss', 'json', 'graphql', 'markdown'] }
 | 
					  " \ 'for': ['javascript', 'typescript', 'css', 'less', 'scss', 'json', 'graphql', 'markdown'] }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Support Org mode
 | 
					" Support Org mode
 | 
				
			||||||
Plugin 'jceb/vim-orgmode'
 | 
					Plugin 'jceb/vim-orgmode'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" ReaosnML
 | 
					 | 
				
			||||||
Plugin 'reasonml-editor/vim-reason-plus'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Autocompletion
 | 
					" Autocompletion
 | 
				
			||||||
Plugin 'junegunn/fzf'
 | 
					Plugin 'junegunn/fzf'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Better JSON highlighting
 | 
					 | 
				
			||||||
Plugin 'elzr/vim-json'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
" Text objects made easy
 | 
					" Text objects made easy
 | 
				
			||||||
Plugin 'kana/vim-textobj-user'
 | 
					Plugin 'kana/vim-textobj-user'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -146,11 +129,11 @@ Plugin 'jiangmiao/auto-pairs'
 | 
				
			||||||
" Linting & error warnings
 | 
					" Linting & error warnings
 | 
				
			||||||
Plugin 'vim-syntastic/syntastic'
 | 
					Plugin 'vim-syntastic/syntastic'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Atom colorscheme
 | 
					" Angular.js support
 | 
				
			||||||
Plugin 'rakr/vim-one'
 | 
					Plugin 'burnettk/vim-angular'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Nix syntax highlighting
 | 
					" Asynchronous Linting Engine
 | 
				
			||||||
Plugin 'LnL7/vim-nix'
 | 
					Plugin 'w0rp/ale'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
call vundle#end()            " required
 | 
					call vundle#end()            " required
 | 
				
			||||||
filetype plugin indent on    " required
 | 
					filetype plugin indent on    " required
 | 
				
			||||||
| 
						 | 
					@ -182,7 +165,11 @@ autocmd FileType reason nnoremap <buffer> gr :call LanguageClient_textDocument_r
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Replace <CR> with G for faster navigation
 | 
					" Replace <CR> with G for faster navigation
 | 
				
			||||||
nnoremap <CR> G
 | 
					nnoremap <CR> G
 | 
				
			||||||
 | 
					onoremap <CR> G
 | 
				
			||||||
 | 
					vnoremap <CR> G
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Mirror ZLE KBD
 | 
				
			||||||
 | 
					inoremap <M-'> :echo "Working"<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Syntastic configuration
 | 
					" Syntastic configuration
 | 
				
			||||||
set statusline+=%#warningmsg#
 | 
					set statusline+=%#warningmsg#
 | 
				
			||||||
| 
						 | 
					@ -193,17 +180,17 @@ let g:syntastic_always_populate_loc_list = 1
 | 
				
			||||||
let g:syntastic_auto_loc_list = 1
 | 
					let g:syntastic_auto_loc_list = 1
 | 
				
			||||||
let g:syntastic_check_on_open = 1
 | 
					let g:syntastic_check_on_open = 1
 | 
				
			||||||
let g:syntastic_check_on_wq = 0
 | 
					let g:syntastic_check_on_wq = 0
 | 
				
			||||||
let g:syntastic_javascript_checkers = ['eslint']
 | 
					" let g:syntastic_javascript_checkers = ['eslint']
 | 
				
			||||||
let g:syntastic_javascript_eslint_generic = 1
 | 
					let g:syntastic_javascript_eslint_generic = 1
 | 
				
			||||||
" this is a hack to prevent a false negative
 | 
					" this is a hack to prevent a false negative
 | 
				
			||||||
" https://github.com/vim-syntastic/syntastic/issues/1692
 | 
					" https://github.com/vim-syntastic/syntastic/issues/1692
 | 
				
			||||||
let g:syntastic_javascript_eslint_exec = '/bin/ls'
 | 
					" let g:syntastic_javascript_eslint_exec = '/bin/ls'
 | 
				
			||||||
let g:syntastic_javascript_eslint_exe = 'npx eslint'
 | 
					" let g:syntastic_javascript_eslint_exe = 'npx eslint'
 | 
				
			||||||
let g:syntastic_javascript_eslint_args = '-f compact'
 | 
					" let g:syntastic_javascript_eslint_args = '-f compact'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" javascript autocompletion
 | 
					" javascript autocompletion
 | 
				
			||||||
autocmd FileType javascript setlocal omnifunc=javascriptcomplete#CompleteJS
 | 
					" autocmd FileType javascript setlocal omnifunc=javascriptcomplete#CompleteJS
 | 
				
			||||||
autocmd FileType javascript nnoremap <buffer> gf :Prettier<CR>
 | 
					" autocmd FileType javascript nnoremap <buffer> gf :Prettier<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Maximize the current window
 | 
					" Maximize the current window
 | 
				
			||||||
" Similar to Tmux mapping alt-z in my tmux.conf
 | 
					" Similar to Tmux mapping alt-z in my tmux.conf
 | 
				
			||||||
| 
						 | 
					@ -213,9 +200,9 @@ nnoremap t% :tab sp<CR>
 | 
				
			||||||
cnoremap <C-g> <C-c>
 | 
					cnoremap <C-g> <C-c>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Prettier configuration
 | 
					" Prettier configuration
 | 
				
			||||||
let g:prettier#exec_cmd_async = 1
 | 
					" let g:prettier#exec_cmd_async = 1
 | 
				
			||||||
" force Prettier to run on files even without the @format pragma
 | 
					" force Prettier to run on files even without the @format pragma
 | 
				
			||||||
let g:prettier#autoformat = 0
 | 
					" let g:prettier#autoformat = 0
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Basic settings
 | 
					" Basic settings
 | 
				
			||||||
| 
						 | 
					@ -232,8 +219,7 @@ set shiftwidth=2
 | 
				
			||||||
set background=dark
 | 
					set background=dark
 | 
				
			||||||
 | 
					
 | 
				
			||||||
syntax enable
 | 
					syntax enable
 | 
				
			||||||
colorscheme one
 | 
					colorscheme peacock
 | 
				
			||||||
set background=dark
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Vim in terminal cannot have a different font from the one set within your
 | 
					" Vim in terminal cannot have a different font from the one set within your
 | 
				
			||||||
" terminal. However, this setting will set the font for the GUI version.
 | 
					" terminal. However, this setting will set the font for the GUI version.
 | 
				
			||||||
| 
						 | 
					@ -309,6 +295,12 @@ augroup my_error_signs
 | 
				
			||||||
augroup END
 | 
					augroup END
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" templates
 | 
				
			||||||
 | 
					if has("autocmd")
 | 
				
			||||||
 | 
					  autocmd BufNewFile *.c  0r ~/.config/nvim/templates/boilerplate.c
 | 
				
			||||||
 | 
					  autocmd BufNewFile *.rs 0r ~/.config/nvim/templates/boilerplate.rs
 | 
				
			||||||
 | 
					endif
 | 
				
			||||||
 | 
					
 | 
				
			||||||
let g:neomake_error_sign = {
 | 
					let g:neomake_error_sign = {
 | 
				
			||||||
            \ 'text': '>>',
 | 
					            \ 'text': '>>',
 | 
				
			||||||
            \ 'texthl': 'NeoMakeErrorSign',
 | 
					            \ 'texthl': 'NeoMakeErrorSign',
 | 
				
			||||||
| 
						 | 
					@ -498,6 +490,15 @@ inoremap <C-f> <Right>
 | 
				
			||||||
inoremap <C-p> <Up>
 | 
					inoremap <C-p> <Up>
 | 
				
			||||||
inoremap <C-n> <Down>
 | 
					inoremap <C-n> <Down>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" temporarily disable <C-p> in normal mode so it doesn't attempt to index all of
 | 
				
			||||||
 | 
					" Google3.
 | 
				
			||||||
 | 
					nnoremap <C-p> :echo "You are attempting to index all of Google3. Aborting..."<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" tab maintenence
 | 
				
			||||||
 | 
					nnoremap <C-t> :tabnew<CR>
 | 
				
			||||||
 | 
					nnoremap <C-w> :tabclose<CR>
 | 
				
			||||||
 | 
					nnoremap <Tab> :tabnext<CR>
 | 
				
			||||||
 | 
					nnoremap <S-Tab> :tabprevious<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Manage Vertical and Horizontal splits
 | 
					" Manage Vertical and Horizontal splits
 | 
				
			||||||
nnoremap sl <Esc>:vs<CR><C-w>l
 | 
					nnoremap sl <Esc>:vs<CR><C-w>l
 | 
				
			||||||
| 
						 | 
					@ -615,7 +616,8 @@ vnoremap // y/<C-r>"<CR>N
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" trim trailing whitespace on save
 | 
					" trim trailing whitespace on save
 | 
				
			||||||
autocmd BufWritePre *.{js,py,tpl,less,html,ex,exs,txt} :%s/\s\+$//e
 | 
					" Are there any file type where I wouldn't want this?
 | 
				
			||||||
 | 
					autocmd BufWritePre *.{js,py,tpl,less,html,ex,exs,txt,hs,java,rs,ml} :%s/\s\+$//e
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
" Use .gitignore file to populate Ctrl-P
 | 
					" Use .gitignore file to populate Ctrl-P
 | 
				
			||||||
							
								
								
									
										98
									
								
								configs/shared/.config/nvim/simple.vim
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										98
									
								
								configs/shared/.config/nvim/simple.vim
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,98 @@
 | 
				
			||||||
 | 
					" My barebones vimrc without any Vundle dependencies.
 | 
				
			||||||
 | 
					"
 | 
				
			||||||
 | 
					" I'm attempting to optimize the following:
 | 
				
			||||||
 | 
					" - Minimize dependencies
 | 
				
			||||||
 | 
					" - Maximize ergonomics
 | 
				
			||||||
 | 
					" - Maximize Tmux compatibility
 | 
				
			||||||
 | 
					" - Minimize shadowing of existing Vim KBDs
 | 
				
			||||||
 | 
					"
 | 
				
			||||||
 | 
					" Warning: This is currently unstable as it is a work-in-progress.
 | 
				
			||||||
 | 
					"
 | 
				
			||||||
 | 
					" Author: William Carroll <wpcarro@gmail.com>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Use <Space> as the leader key.
 | 
				
			||||||
 | 
					let mapleader = " "
 | 
				
			||||||
 | 
					nnoremap <leader>ev :tabnew<CR>:edit ~/.vimrc<CR>
 | 
				
			||||||
 | 
					nnoremap <leader>sv :source ~/.vimrc<CR>
 | 
				
			||||||
 | 
					nnoremap <leader>w  :w<CR>
 | 
				
			||||||
 | 
					nnoremap <leader>h  :help 
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" increment,decrement numbers
 | 
				
			||||||
 | 
					nnoremap + <C-a>
 | 
				
			||||||
 | 
					" TODO: Restore with better KBD
 | 
				
			||||||
 | 
					" nnoremap - <C-x>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Visit the CWD
 | 
				
			||||||
 | 
					nnoremap - :e .<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Turn line numbers on.
 | 
				
			||||||
 | 
					set number
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Easily create vertical, horizontal window splits.
 | 
				
			||||||
 | 
					nnoremap sh :vsplit<CR>
 | 
				
			||||||
 | 
					nnoremap sj :split<CR>:wincmd j<CR>
 | 
				
			||||||
 | 
					nnoremap sk :split<CR>
 | 
				
			||||||
 | 
					nnoremap sl :vsplit<CR>:wincmd l<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Move across window splits.
 | 
				
			||||||
 | 
					" TODO: Change to <M-{h,j,k,l}>.
 | 
				
			||||||
 | 
					nnoremap <C-h> :wincmd h<CR>
 | 
				
			||||||
 | 
					nnoremap <C-j> :wincmd j<CR>
 | 
				
			||||||
 | 
					nnoremap <C-k> :wincmd k<CR>
 | 
				
			||||||
 | 
					nnoremap <C-l> :wincmd l<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" TODO: Support these.
 | 
				
			||||||
 | 
					" nnoremap <M-q> :q<CR>
 | 
				
			||||||
 | 
					" nnoremap <M-h> :wincmd h<CR>
 | 
				
			||||||
 | 
					" nnoremap <M-j> :wincmd j<CR>
 | 
				
			||||||
 | 
					" nnoremap <M-k> :wincmd k<CR>
 | 
				
			||||||
 | 
					" nnoremap <M-l> :wincmd l<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Use <Enter> instead of G to support:
 | 
				
			||||||
 | 
					"        20<Enter> - to jump to line 20
 | 
				
			||||||
 | 
					"       d20<Enter> - to delete from the current line until line 20
 | 
				
			||||||
 | 
					"   <C-v>20<Enter> - to select from the current line until line 20
 | 
				
			||||||
 | 
					nnoremap <Enter> G
 | 
				
			||||||
 | 
					onoremap <Enter> G
 | 
				
			||||||
 | 
					vnoremap <Enter> G
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Easily change modes on keyboards that don't have CapsLock mapped to <Esc>
 | 
				
			||||||
 | 
					inoremap jk      <ESC>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" CRUD tabs.
 | 
				
			||||||
 | 
					nnoremap <TAB>   :tabnext<CR>
 | 
				
			||||||
 | 
					nnoremap <S-TAB> :tabprevious<CR>
 | 
				
			||||||
 | 
					nnoremap <C-t>   :tabnew<CR>:edit .<CR>
 | 
				
			||||||
 | 
					nnoremap <C-w>   :tabclose<CR>
 | 
				
			||||||
 | 
					" TODO: Re-enable these once <M-{h,j,k,l}> are supported.
 | 
				
			||||||
 | 
					" nnoremap <C-l> :+tabmove<CR>
 | 
				
			||||||
 | 
					" nnoremap <C-h> :-tabmove<CR>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Use H,L to goto beggining,end of a line.
 | 
				
			||||||
 | 
					" Swaps the keys to ensure original functionality of H,L are preserved.
 | 
				
			||||||
 | 
					nnoremap H ^
 | 
				
			||||||
 | 
					nnoremap L $
 | 
				
			||||||
 | 
					nnoremap ^ H
 | 
				
			||||||
 | 
					nnoremap $ L
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Use H,L in visual mode too
 | 
				
			||||||
 | 
					vnoremap H ^
 | 
				
			||||||
 | 
					vnoremap L $
 | 
				
			||||||
 | 
					vnoremap ^ H
 | 
				
			||||||
 | 
					vnoremap $ L
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Emacs hybrid mode
 | 
				
			||||||
 | 
					" TODO: model this after tpope's rsi.vim (Readline-style insertion)
 | 
				
			||||||
 | 
					cnoremap <C-g> <C-c>
 | 
				
			||||||
 | 
					cnoremap <C-a> <C-b>
 | 
				
			||||||
 | 
					inoremap <C-a> <C-o>^
 | 
				
			||||||
 | 
					inoremap <C-e> <C-o>$
 | 
				
			||||||
 | 
					inoremap <C-b> <C-o>h
 | 
				
			||||||
 | 
					inoremap <C-f> <C-o>l
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					" Indenting
 | 
				
			||||||
 | 
					" The following three settings are based on option 2 of `:help tabstop`
 | 
				
			||||||
 | 
					set tabstop=4
 | 
				
			||||||
 | 
					set shiftwidth=4
 | 
				
			||||||
 | 
					set expandtab
 | 
				
			||||||
 | 
					set autoindent
 | 
				
			||||||
							
								
								
									
										6
									
								
								configs/shared/.config/nvim/templates/boilerplate.c
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								configs/shared/.config/nvim/templates/boilerplate.c
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,6 @@
 | 
				
			||||||
 | 
					#include <stdio.h>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					int main() {
 | 
				
			||||||
 | 
					  printf("Hello, world!");
 | 
				
			||||||
 | 
					  return 0;
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
							
								
								
									
										5
									
								
								configs/shared/.config/nvim/templates/boilerplate.rs
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								configs/shared/.config/nvim/templates/boilerplate.rs
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,5 @@
 | 
				
			||||||
 | 
					fn main() {
 | 
				
			||||||
 | 
					    // The statements here will be executed when the compiled binary is called.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    println!("Hello, world!");
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
							
								
								
									
										6
									
								
								configs/shared/.config/rofi/config
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								configs/shared/.config/rofi/config
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,6 @@
 | 
				
			||||||
 | 
					rofi.font:                           Monospace 10
 | 
				
			||||||
 | 
					rofi.color-normal:                   #31213f, #8de0e1, #31213f, #83526a, #8de0e1
 | 
				
			||||||
 | 
					rofi.color-urgent:                   #31213f, #d6b48d, #22231D, #d6b48d, #8de0e1
 | 
				
			||||||
 | 
					rofi.color-active:                   #31213f, #3CC2B5, #31213f, #3CC2B5, #31213f
 | 
				
			||||||
 | 
					rofi.color-window:                   #31213f, #83526a, #5a3849
 | 
				
			||||||
 | 
					rofi.modi: window,run,ssh,combi
 | 
				
			||||||
							
								
								
									
										6
									
								
								configs/shared/.config/rofi/config.bak
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								configs/shared/.config/rofi/config.bak
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,6 @@
 | 
				
			||||||
 | 
					rofi.font:                           Source Code Pro 10
 | 
				
			||||||
 | 
					rofi.color-normal:                   #01022E, #a7dff4, #01022E, #015f9e, #a7dff4
 | 
				
			||||||
 | 
					rofi.color-urgent:                   #01022E, #d6b48d, #22231D, #d6b48d, #a7dff4
 | 
				
			||||||
 | 
					rofi.color-active:                   #01022E, #3FA4E0, #01022E, #3FA4E0, #01022E
 | 
				
			||||||
 | 
					rofi.color-window:                   #01022E, #015f9e, #01416c
 | 
				
			||||||
 | 
					rofi.modi: window,run,ssh,combi
 | 
				
			||||||
							
								
								
									
										18
									
								
								configs/shared/.config/systemd/user/clipmenud.service
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										18
									
								
								configs/shared/.config/systemd/user/clipmenud.service
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,18 @@
 | 
				
			||||||
 | 
					[Unit]
 | 
				
			||||||
 | 
					Description=Clipmenu daemon
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					[Service]
 | 
				
			||||||
 | 
					ExecStart=clipmenud
 | 
				
			||||||
 | 
					Restart=always
 | 
				
			||||||
 | 
					RestartSec=500ms
 | 
				
			||||||
 | 
					Environment=DISPLAY=:0
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					MemoryDenyWriteExecute=yes
 | 
				
			||||||
 | 
					NoNewPrivileges=yes
 | 
				
			||||||
 | 
					ProtectControlGroups=yes
 | 
				
			||||||
 | 
					ProtectKernelTunables=yes
 | 
				
			||||||
 | 
					RestrictAddressFamilies=
 | 
				
			||||||
 | 
					RestrictRealtime=yes
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					[Install]
 | 
				
			||||||
 | 
					WantedBy=default.target
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					/usr/local/google/home/wpcarro/.config/systemd/user/clipmenud.service
 | 
				
			||||||
							
								
								
									
										34
									
								
								configs/shared/.config/terminator/config
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										34
									
								
								configs/shared/.config/terminator/config
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,34 @@
 | 
				
			||||||
 | 
					[global_config]
 | 
				
			||||||
 | 
					  enabled_plugins = LaunchpadBugURLHandler, LaunchpadCodeURLHandler, APTURLHandler, TerminatorThemes
 | 
				
			||||||
 | 
					[keybindings]
 | 
				
			||||||
 | 
					[profiles]
 | 
				
			||||||
 | 
					  [[default]]
 | 
				
			||||||
 | 
					    background_color = "#ffffff"
 | 
				
			||||||
 | 
					    cursor_shape = ibeam
 | 
				
			||||||
 | 
					    cursor_color = "#E29B61"
 | 
				
			||||||
 | 
					    font = Input Mono Medium 12
 | 
				
			||||||
 | 
					    foreground_color = "#000000"
 | 
				
			||||||
 | 
					    show_titlebar = False
 | 
				
			||||||
 | 
					    scrollbar_position = hidden
 | 
				
			||||||
 | 
					    palette = "#31213f:#e29b61:#e8c35f:#565b87:#a56785:#20a89e:#3cc2b5:#8de0e1:#629c9d:#e29b61:#e8c35f:#565b87:#a56785:#20a89e:#3cc2b5:#8de0e1"
 | 
				
			||||||
 | 
					    use_system_font = False
 | 
				
			||||||
 | 
					  [[Molokai]]
 | 
				
			||||||
 | 
					    background_color = "#121212"
 | 
				
			||||||
 | 
					    cursor_shape = ibeam
 | 
				
			||||||
 | 
					    cursor_color = "#bbbbbb"
 | 
				
			||||||
 | 
					    font = Input Mono Medium 12
 | 
				
			||||||
 | 
					    foreground_color = "#bbbbbb"
 | 
				
			||||||
 | 
					    show_titlebar = False
 | 
				
			||||||
 | 
					    scrollbar_position = hidden
 | 
				
			||||||
 | 
					    palette = "#121212:#fa2573:#98e123:#dfd460:#1080d0:#8700ff:#43a8d0:#bbbbbb:#555555:#f6669d:#b1e05f:#fff26d:#00afff:#af87ff:#51ceff:#ffffff"
 | 
				
			||||||
 | 
					    use_system_font = False
 | 
				
			||||||
 | 
					[layouts]
 | 
				
			||||||
 | 
					  [[default]]
 | 
				
			||||||
 | 
					    [[[child1]]]
 | 
				
			||||||
 | 
					      parent = window0
 | 
				
			||||||
 | 
					      type = Terminal
 | 
				
			||||||
 | 
					      profile = Molokai
 | 
				
			||||||
 | 
					    [[[window0]]]
 | 
				
			||||||
 | 
					      parent = ""
 | 
				
			||||||
 | 
					      type = Window
 | 
				
			||||||
 | 
					[plugins]
 | 
				
			||||||
							
								
								
									
										23
									
								
								configs/shared/.config/terminator/config.bak
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								configs/shared/.config/terminator/config.bak
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,23 @@
 | 
				
			||||||
 | 
					[global_config]
 | 
				
			||||||
 | 
					  enabled_plugins = LaunchpadBugURLHandler, LaunchpadCodeURLHandler, APTURLHandler
 | 
				
			||||||
 | 
					[keybindings]
 | 
				
			||||||
 | 
					[profiles]
 | 
				
			||||||
 | 
					  [[default]]
 | 
				
			||||||
 | 
					    background_color = "#01022E"
 | 
				
			||||||
 | 
					    cursor_shape = ibeam
 | 
				
			||||||
 | 
					    cursor_color = "#434AA6"
 | 
				
			||||||
 | 
					    font = Source Code Pro 10
 | 
				
			||||||
 | 
					    foreground_color = "#0278C6"
 | 
				
			||||||
 | 
					    show_titlebar = False
 | 
				
			||||||
 | 
					    scrollbar_position = hidden
 | 
				
			||||||
 | 
					    palette = "#01022E:#434AA6:#0278C6:#9B6DB0:#018CD5:#07AAE9:#3FA4E0:#a7dff4:#749caa:#434AA6:#0278C6:#9B6DB0:#018CD5:#07AAE9:#3FA4E0:#a7dff4"
 | 
				
			||||||
 | 
					    use_system_font = False
 | 
				
			||||||
 | 
					[layouts]
 | 
				
			||||||
 | 
					  [[default]]
 | 
				
			||||||
 | 
					    [[[child1]]]
 | 
				
			||||||
 | 
					      parent = window0
 | 
				
			||||||
 | 
					      type = Terminal
 | 
				
			||||||
 | 
					    [[[window0]]]
 | 
				
			||||||
 | 
					      parent = ""
 | 
				
			||||||
 | 
					      type = Window
 | 
				
			||||||
 | 
					[plugins]
 | 
				
			||||||
							
								
								
									
										250
									
								
								configs/shared/.config/terminator/plugins/terminator-themes.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										250
									
								
								configs/shared/.config/terminator/plugins/terminator-themes.py
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,250 @@
 | 
				
			||||||
 | 
					import requests
 | 
				
			||||||
 | 
					import terminatorlib.plugin as plugin
 | 
				
			||||||
 | 
					from gi.repository import Gtk
 | 
				
			||||||
 | 
					from terminatorlib.config import ConfigBase
 | 
				
			||||||
 | 
					from terminatorlib.translation import _
 | 
				
			||||||
 | 
					from terminatorlib.util import get_config_dir, err, dbg, gerr
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					AVAILABLE = ['TerminatorThemes']
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					class TerminatorThemes(plugin.Plugin):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    capabilities = ['terminal_menu']
 | 
				
			||||||
 | 
					    config_base = ConfigBase()
 | 
				
			||||||
 | 
					    base_url = 'https://api.github.com/repos/EliverLara/terminator-themes/contents/themes.json'
 | 
				
			||||||
 | 
					    inherits_config_from = "default"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def callback(self, menuitems, menu, terminal):
 | 
				
			||||||
 | 
					        """Add our item to the menu"""
 | 
				
			||||||
 | 
					        self.terminal = terminal
 | 
				
			||||||
 | 
					        item = Gtk.ImageMenuItem(Gtk.STOCK_FIND)
 | 
				
			||||||
 | 
					        item.connect('activate',self.configure)
 | 
				
			||||||
 | 
					        item.set_label("Themes")
 | 
				
			||||||
 | 
					        item.set_sensitive(True)
 | 
				
			||||||
 | 
					        menuitems.append(item)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def configure(self, widget, data = None):
 | 
				
			||||||
 | 
					        ui = {}
 | 
				
			||||||
 | 
					        dbox = Gtk.Dialog( _("Terminator themes"), None, Gtk.DialogFlags.MODAL)
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					        headers = { "Accept": "application/vnd.github.v3.raw" }
 | 
				
			||||||
 | 
					        response = requests.get(self.base_url, headers=headers)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        if response.status_code != 200:
 | 
				
			||||||
 | 
					            gerr(_("Failed to get list of available themes"))
 | 
				
			||||||
 | 
					            return
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					        self.themes_from_repo = response.json()["themes"]
 | 
				
			||||||
 | 
					        self.profiles = self.terminal.config.list_profiles()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        main_container = Gtk.HBox(spacing=5)
 | 
				
			||||||
 | 
					        main_container.pack_start(self._create_themes_grid(ui), True, True, 0)
 | 
				
			||||||
 | 
					        main_container.pack_start(self._create_settings_grid(ui), True, True, 0)
 | 
				
			||||||
 | 
					        dbox.vbox.pack_start(main_container, True, True, 0)
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					        self.dbox = dbox
 | 
				
			||||||
 | 
					        dbox.show_all()
 | 
				
			||||||
 | 
					        res = dbox.run()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        if res == Gtk.ResponseType.ACCEPT:
 | 
				
			||||||
 | 
					            self.terminal.config.save()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        del(self.dbox)
 | 
				
			||||||
 | 
					        dbox.destroy()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _create_themes_grid(self, ui):
 | 
				
			||||||
 | 
					        grid = Gtk.Grid()
 | 
				
			||||||
 | 
					        grid.set_column_spacing(5)
 | 
				
			||||||
 | 
					        grid.set_row_spacing(7)
 | 
				
			||||||
 | 
					        grid.set_column_homogeneous(True)
 | 
				
			||||||
 | 
					        grid.set_row_homogeneous(True)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        scroll_window = self._create_themes_list(ui)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        #creating buttons to filter by theme type, and setting up their events
 | 
				
			||||||
 | 
					        buttons = list()
 | 
				
			||||||
 | 
					        for theme_type in ["light", "dark", "None"]:
 | 
				
			||||||
 | 
					            button = Gtk.Button(theme_type)
 | 
				
			||||||
 | 
					            buttons.append(button)
 | 
				
			||||||
 | 
					            button.connect("clicked", self.on_filter_button_clicked)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        grid.attach(scroll_window, 0, 0, 4, 10)
 | 
				
			||||||
 | 
					        grid.attach_next_to(buttons[0], scroll_window, Gtk.PositionType.BOTTOM, 1, 1)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        for i, button in enumerate(buttons[1:]):
 | 
				
			||||||
 | 
					            grid.attach_next_to(button, buttons[i], Gtk.PositionType.RIGHT, 1, 1)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        return grid
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _create_themes_list(self, ui):
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        profiles_list_model = Gtk.ListStore(str, str,bool, object)
 | 
				
			||||||
 | 
					        # Set add/remove buttons availability
 | 
				
			||||||
 | 
					        for theme in self.themes_from_repo:
 | 
				
			||||||
 | 
					            if theme["name"] in self.profiles:
 | 
				
			||||||
 | 
					                profiles_list_model.append([theme["name"], theme["type"],False, theme])
 | 
				
			||||||
 | 
					            else:
 | 
				
			||||||
 | 
					                profiles_list_model.append([theme["name"], theme["type"],True, theme])
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        self.current_filter_theme = None
 | 
				
			||||||
 | 
					        self.theme_filter = profiles_list_model.filter_new()
 | 
				
			||||||
 | 
					        self.theme_filter.set_visible_func(self.theme_filter_func)
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					        treeview = Gtk.TreeView.new_with_model(self.theme_filter)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        selection = treeview.get_selection()
 | 
				
			||||||
 | 
					        selection.set_mode(Gtk.SelectionMode.SINGLE)
 | 
				
			||||||
 | 
					        selection.connect("changed", self.on_selection_changed, ui)
 | 
				
			||||||
 | 
					        ui['treeview'] = treeview
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        for i, column_title in enumerate(["Theme", "Type"]):
 | 
				
			||||||
 | 
					            renderer = Gtk.CellRendererText()
 | 
				
			||||||
 | 
					            column = Gtk.TreeViewColumn(column_title, renderer, text=i)
 | 
				
			||||||
 | 
					            treeview.append_column(column)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        scroll_window = Gtk.ScrolledWindow()
 | 
				
			||||||
 | 
					        scroll_window.set_policy(Gtk.PolicyType.AUTOMATIC, Gtk.PolicyType.AUTOMATIC)
 | 
				
			||||||
 | 
					        scroll_window.add(treeview)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        return scroll_window
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _create_settings_grid(self, ui):
 | 
				
			||||||
 | 
					        grid = Gtk.Grid()
 | 
				
			||||||
 | 
					        grid.set_column_spacing(5)
 | 
				
			||||||
 | 
					        grid.set_row_spacing(7)
 | 
				
			||||||
 | 
					        grid.attach(self._create_default_inherits_check(ui), 0, 0, 2, 1)
 | 
				
			||||||
 | 
					        grid.attach(Gtk.Label("Available profiles: "), 0, 1, 1, 1)
 | 
				
			||||||
 | 
					        grid.attach(self._create_inherits_from_combo(ui), 1, 1, 1, 1)
 | 
				
			||||||
 | 
					        grid.attach(self._create_main_action_button(ui, "install", self.on_install), 0, 4, 1, 1)
 | 
				
			||||||
 | 
					        grid.attach(self._create_main_action_button(ui, "remove", self.on_uninstall), 1, 4, 1, 1)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        return grid
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _create_default_inherits_check(self, ui):
 | 
				
			||||||
 | 
					        check = Gtk.CheckButton("Inherit preferences from default profile")
 | 
				
			||||||
 | 
					        check.set_active(True)
 | 
				
			||||||
 | 
					        check.connect("toggled", self.on_inheritsfromdefaultcheck_toggled, ui)
 | 
				
			||||||
 | 
					        ui['check_inherits_from_default'] = check
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					        return check
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def _create_inherits_from_combo(self, ui):
 | 
				
			||||||
 | 
					        combo = Gtk.ComboBoxText()
 | 
				
			||||||
 | 
					        combo.set_entry_text_column(0)
 | 
				
			||||||
 | 
					        combo.set_sensitive(False)
 | 
				
			||||||
 | 
					        combo.connect("changed", self.on_inheritsfromcombo_changed, ui)
 | 
				
			||||||
 | 
					        ui['inherits_from_combo'] = combo
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        for profile in self.profiles:
 | 
				
			||||||
 | 
					            combo.append_text(profile)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        combo.set_active(self.profiles.index(self.terminal.config.get_profile()))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        return combo
 | 
				
			||||||
 | 
					    
 | 
				
			||||||
 | 
					    def _create_main_action_button(self, ui, label, action):
 | 
				
			||||||
 | 
					        btn = Gtk.Button(_(label.capitalize()))
 | 
				
			||||||
 | 
					        btn.connect("clicked", action, ui) 
 | 
				
			||||||
 | 
					        btn.set_sensitive(False)
 | 
				
			||||||
 | 
					        ui['button_' + label] = btn
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        return btn
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def theme_filter_func(self, model, iter, data):
 | 
				
			||||||
 | 
					        """Tests if the theme in the row is the one in the filter"""
 | 
				
			||||||
 | 
					        if self.current_filter_theme is None or self.current_filter_theme == "None":
 | 
				
			||||||
 | 
					            return True
 | 
				
			||||||
 | 
					        else:
 | 
				
			||||||
 | 
					            return model[iter][1] == self.current_filter_theme
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def on_filter_button_clicked(self, widget):
 | 
				
			||||||
 | 
					        """Called on any of the button clicks"""
 | 
				
			||||||
 | 
					        #we set the current theme filter to the button's label
 | 
				
			||||||
 | 
					        self.current_filter_theme = widget.get_label()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        #we update the filter, which updates in turn the view
 | 
				
			||||||
 | 
					        self.theme_filter.refilter()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def  on_inheritsfromdefaultcheck_toggled(self, check, data=None):
 | 
				
			||||||
 | 
					        if check.get_active() is not True:
 | 
				
			||||||
 | 
					            data["inherits_from_combo"].set_sensitive(True)
 | 
				
			||||||
 | 
					            self.inherits_config_from = self.profiles[data['inherits_from_combo'].get_active()]
 | 
				
			||||||
 | 
					        else:
 | 
				
			||||||
 | 
					            data["inherits_from_combo"].set_sensitive(False)
 | 
				
			||||||
 | 
					            self.inherits_config_from = 'default'
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					    def  on_inheritsfromcombo_changed(self, combo, data):
 | 
				
			||||||
 | 
					        if combo.get_sensitive():    
 | 
				
			||||||
 | 
					            self.inherits_config_from = self.profiles[combo.get_active()]
 | 
				
			||||||
 | 
					        else:
 | 
				
			||||||
 | 
					            self.inherits_config_from = 'default'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def on_selection_changed(self, selection, data=None):
 | 
				
			||||||
 | 
					        (model, iter) = selection.get_selected()
 | 
				
			||||||
 | 
					        data['button_install'].set_sensitive(model[iter][2])
 | 
				
			||||||
 | 
					        data['button_remove'].set_sensitive(model[iter][2] is not True)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def on_uninstall(self, button, data):
 | 
				
			||||||
 | 
					        treeview = data['treeview']
 | 
				
			||||||
 | 
					        selection = treeview.get_selection()
 | 
				
			||||||
 | 
					        (store, iter) = selection.get_selected()
 | 
				
			||||||
 | 
					        target = store[iter][0]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        # If selected theme is active, sets terminal profile to default before unistalling
 | 
				
			||||||
 | 
					        if self.terminal.get_profile() == target:
 | 
				
			||||||
 | 
					            widget = self.terminal.get_vte()
 | 
				
			||||||
 | 
					            self.terminal.force_set_profile(widget, 'default')
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        self.terminal.config.del_profile(target)
 | 
				
			||||||
 | 
					        self.terminal.config.save()
 | 
				
			||||||
 | 
					        self.update_comboInheritsFrom(data)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        #'Add' button available again
 | 
				
			||||||
 | 
					        data['treeview'].get_model().set_value(iter, 2, True)
 | 
				
			||||||
 | 
					        self.on_selection_changed(selection, data)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def on_install(self, button, data):
 | 
				
			||||||
 | 
					        treeview = data['treeview']
 | 
				
			||||||
 | 
					        selection = treeview.get_selection()
 | 
				
			||||||
 | 
					        (store, iter) = selection.get_selected()
 | 
				
			||||||
 | 
					        target = store[iter][3]
 | 
				
			||||||
 | 
					        widget = self.terminal.get_vte()
 | 
				
			||||||
 | 
					        treeview.set_enable_tree_lines(False)
 | 
				
			||||||
 | 
					        
 | 
				
			||||||
 | 
					        if not iter:
 | 
				
			||||||
 | 
					            return
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        self.terminal.config.add_profile(target["name"]) 
 | 
				
			||||||
 | 
					        template_data = self.config_base.profiles[self.inherits_config_from].copy()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        for k, v in target.items():
 | 
				
			||||||
 | 
					            if k != 'background_image' and k != 'name' and k != 'type':
 | 
				
			||||||
 | 
					                if k == 'background_darkness':
 | 
				
			||||||
 | 
					                    template_data[k] = float(v)
 | 
				
			||||||
 | 
					                else:
 | 
				
			||||||
 | 
					                    template_data[k] = v
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        for k, v in template_data.items():
 | 
				
			||||||
 | 
					            self.config_base.set_item(k, v, target["name"])
 | 
				
			||||||
 | 
					                 
 | 
				
			||||||
 | 
					        self.terminal.force_set_profile(widget, target["name"])
 | 
				
			||||||
 | 
					        self.terminal.config.save()
 | 
				
			||||||
 | 
					        self.update_comboInheritsFrom(data)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        # "Remove" button available again
 | 
				
			||||||
 | 
					        data['treeview'].get_model().set_value(iter, 2, False)
 | 
				
			||||||
 | 
					        self.on_selection_changed(selection, data)
 | 
				
			||||||
 | 
					        treeview.set_enable_tree_lines(True)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    def update_comboInheritsFrom(self, data):
 | 
				
			||||||
 | 
					        data['inherits_from_combo'].remove_all()
 | 
				
			||||||
 | 
					        profiles = self.terminal.config.list_profiles()
 | 
				
			||||||
 | 
					        self.profiles = profiles
 | 
				
			||||||
 | 
					        for profile in profiles:
 | 
				
			||||||
 | 
					            data['inherits_from_combo'].append_text(profile)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					        data['inherits_from_combo'].set_active(profiles.index(self.terminal.config.get_profile()))
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.docker/.buildNodeID
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.docker/.buildNodeID
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					fba49875b86b20c987649381fe9160d51df53e6836665499ded0e9fb90709e85
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,51 @@
 | 
				
			||||||
 | 
					(require 'wpc-package "~/.emacs.d/wpc/packages/wpc-package.el")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; load order is intentional
 | 
				
			||||||
 | 
					(require 'constants)
 | 
				
			||||||
 | 
					(require 'wpc-misc)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; my libraries
 | 
				
			||||||
 | 
					(require 'functions)
 | 
				
			||||||
 | 
					(require 'prelude)
 | 
				
			||||||
 | 
					(require 'macros)
 | 
				
			||||||
 | 
					(require 'kaomoji)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; Google
 | 
				
			||||||
 | 
					(require 'google-tooling)
 | 
				
			||||||
 | 
					;; TODO: How should I handle google-stuff.el?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; TODO: Debug why wallpaper is changing randomly.  It seems to happen every 5
 | 
				
			||||||
 | 
					;; seconds when init.el is open...
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; Laptop XF-functionality
 | 
				
			||||||
 | 
					(require 'pulse-audio)
 | 
				
			||||||
 | 
					(require 'screen-brightness)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; miscellaneous
 | 
				
			||||||
 | 
					(require 'clipboard)
 | 
				
			||||||
 | 
					(require 'battery)
 | 
				
			||||||
 | 
					(require 'dotfiles)
 | 
				
			||||||
 | 
					(require 'bookmark)
 | 
				
			||||||
 | 
					(require 'keyboard)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(require 'wpc-keybindings)
 | 
				
			||||||
 | 
					(require 'window-manager)
 | 
				
			||||||
 | 
					(require 'wpc-ui)
 | 
				
			||||||
 | 
					(require 'wpc-dired)
 | 
				
			||||||
 | 
					(require 'wpc-terminal)
 | 
				
			||||||
 | 
					(require 'wpc-org)
 | 
				
			||||||
 | 
					(require 'wpc-company)
 | 
				
			||||||
 | 
					(require 'wpc-flycheck)
 | 
				
			||||||
 | 
					(require 'wpc-shell)
 | 
				
			||||||
 | 
					(require 'wpc-docker)
 | 
				
			||||||
 | 
					(require 'wpc-lisp)
 | 
				
			||||||
 | 
					(require 'wpc-haskell)
 | 
				
			||||||
 | 
					(require 'wpc-reasonml)
 | 
				
			||||||
 | 
					(require 'wpc-ocaml)
 | 
				
			||||||
 | 
					(require 'wpc-elixir)
 | 
				
			||||||
 | 
					(require 'wpc-nix)
 | 
				
			||||||
 | 
					(require 'wpc-rust)
 | 
				
			||||||
 | 
					(require 'wpc-clojure)
 | 
				
			||||||
 | 
					(require 'wpc-python)
 | 
				
			||||||
 | 
					(require 'wpc-javascript)
 | 
				
			||||||
 | 
					(require 'wpc-java)
 | 
				
			||||||
							
								
								
									
										51
									
								
								configs/shared/.emacs.d/init.el
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										51
									
								
								configs/shared/.emacs.d/init.el
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,51 @@
 | 
				
			||||||
 | 
					(require 'wpc-package "~/.emacs.d/wpc/packages/wpc-package.el")
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; load order is intentional
 | 
				
			||||||
 | 
					(require 'constants)
 | 
				
			||||||
 | 
					(require 'wpc-misc)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; my libraries
 | 
				
			||||||
 | 
					(require 'functions)
 | 
				
			||||||
 | 
					(require 'prelude)
 | 
				
			||||||
 | 
					(require 'macros)
 | 
				
			||||||
 | 
					(require 'kaomoji)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; Google
 | 
				
			||||||
 | 
					(require 'google-tooling)
 | 
				
			||||||
 | 
					;; TODO: How should I handle google-stuff.el?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; TODO: Debug why wallpaper is changing randomly.  It seems to happen every 5
 | 
				
			||||||
 | 
					;; seconds when init.el is open...
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; Laptop XF-functionality
 | 
				
			||||||
 | 
					(require 'pulse-audio)
 | 
				
			||||||
 | 
					(require 'screen-brightness)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; miscellaneous
 | 
				
			||||||
 | 
					(require 'clipboard)
 | 
				
			||||||
 | 
					(require 'battery)
 | 
				
			||||||
 | 
					(require 'dotfiles)
 | 
				
			||||||
 | 
					(require 'bookmark)
 | 
				
			||||||
 | 
					(require 'keyboard)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(require 'wpc-keybindings)
 | 
				
			||||||
 | 
					(require 'window-manager)
 | 
				
			||||||
 | 
					(require 'wpc-ui)
 | 
				
			||||||
 | 
					(require 'wpc-dired)
 | 
				
			||||||
 | 
					(require 'wpc-terminal)
 | 
				
			||||||
 | 
					(require 'wpc-org)
 | 
				
			||||||
 | 
					(require 'wpc-company)
 | 
				
			||||||
 | 
					(require 'wpc-flycheck)
 | 
				
			||||||
 | 
					(require 'wpc-shell)
 | 
				
			||||||
 | 
					(require 'wpc-docker)
 | 
				
			||||||
 | 
					(require 'wpc-lisp)
 | 
				
			||||||
 | 
					(require 'wpc-haskell)
 | 
				
			||||||
 | 
					(require 'wpc-reasonml)
 | 
				
			||||||
 | 
					(require 'wpc-ocaml)
 | 
				
			||||||
 | 
					(require 'wpc-elixir)
 | 
				
			||||||
 | 
					(require 'wpc-nix)
 | 
				
			||||||
 | 
					(require 'wpc-rust)
 | 
				
			||||||
 | 
					(require 'wpc-clojure)
 | 
				
			||||||
 | 
					(require 'wpc-python)
 | 
				
			||||||
 | 
					(require 'wpc-javascript)
 | 
				
			||||||
 | 
					(require 'wpc-java)
 | 
				
			||||||
							
								
								
									
										145
									
								
								configs/shared/.emacs.d/opam-user-setup.el
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										145
									
								
								configs/shared/.emacs.d/opam-user-setup.el
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,145 @@
 | 
				
			||||||
 | 
					;; ## added by OPAM user-setup for emacs / base ## cfd3c9b7837c85cffd0c59de521990f0 ## you can edit, but keep this line
 | 
				
			||||||
 | 
					(provide 'opam-user-setup)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					;; Base configuration for OPAM
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-shell-command-to-string (command)
 | 
				
			||||||
 | 
					  "Similar to shell-command-to-string, but returns nil unless the process
 | 
				
			||||||
 | 
					  returned 0, and ignores stderr (shell-command-to-string ignores return value)"
 | 
				
			||||||
 | 
					  (let* ((return-value 0)
 | 
				
			||||||
 | 
					         (return-string
 | 
				
			||||||
 | 
					          (with-output-to-string
 | 
				
			||||||
 | 
					            (setq return-value
 | 
				
			||||||
 | 
					                  (with-current-buffer standard-output
 | 
				
			||||||
 | 
					                    (process-file shell-file-name nil '(t nil) nil
 | 
				
			||||||
 | 
					                                  shell-command-switch command))))))
 | 
				
			||||||
 | 
					    (if (= return-value 0) return-string nil)))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-update-env (switch)
 | 
				
			||||||
 | 
					  "Update the environment to follow current OPAM switch configuration"
 | 
				
			||||||
 | 
					  (interactive
 | 
				
			||||||
 | 
					   (list
 | 
				
			||||||
 | 
					    (let ((default
 | 
				
			||||||
 | 
					            (car (split-string (opam-shell-command-to-string "opam switch show --safe")))))
 | 
				
			||||||
 | 
					      (completing-read
 | 
				
			||||||
 | 
					       (concat "opam switch (" default "): ")
 | 
				
			||||||
 | 
					       (split-string (opam-shell-command-to-string "opam switch list -s --safe") "\n")
 | 
				
			||||||
 | 
					       nil t nil nil default))))
 | 
				
			||||||
 | 
					  (let* ((switch-arg (if (= 0 (length switch)) "" (concat "--switch " switch)))
 | 
				
			||||||
 | 
					         (command (concat "opam config env --safe --sexp " switch-arg))
 | 
				
			||||||
 | 
					         (env (opam-shell-command-to-string command)))
 | 
				
			||||||
 | 
					    (when (and env (not (string= env "")))
 | 
				
			||||||
 | 
					      (dolist (var (car (read-from-string env)))
 | 
				
			||||||
 | 
					        (setenv (car var) (cadr var))
 | 
				
			||||||
 | 
					        (when (string= (car var) "PATH")
 | 
				
			||||||
 | 
					          (setq exec-path (split-string (cadr var) path-separator)))))))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(opam-update-env nil)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defvar opam-share
 | 
				
			||||||
 | 
					  (let ((reply (opam-shell-command-to-string "opam config var share --safe")))
 | 
				
			||||||
 | 
					    (when reply (substring reply 0 -1))))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(add-to-list 'load-path (concat opam-share "/emacs/site-lisp"))
 | 
				
			||||||
 | 
					;; OPAM-installed tools automated detection and initialisation
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-tuareg ()
 | 
				
			||||||
 | 
					  (add-to-list 'load-path (concat opam-share "/tuareg") t)
 | 
				
			||||||
 | 
					  (load "tuareg-site-file"))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-add-ocaml-hook (h)
 | 
				
			||||||
 | 
					  (add-hook 'tuareg-mode-hook h t)
 | 
				
			||||||
 | 
					  (add-hook 'caml-mode-hook h t))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-complete ()
 | 
				
			||||||
 | 
					  (if (require 'company nil t)
 | 
				
			||||||
 | 
					    (opam-setup-add-ocaml-hook
 | 
				
			||||||
 | 
					      (lambda ()
 | 
				
			||||||
 | 
					         (company-mode)
 | 
				
			||||||
 | 
					         (defalias 'auto-complete 'company-complete)))
 | 
				
			||||||
 | 
					    (require 'auto-complete nil t)))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-ocp-indent ()
 | 
				
			||||||
 | 
					  (opam-setup-complete)
 | 
				
			||||||
 | 
					  (autoload 'ocp-setup-indent "ocp-indent" "Improved indentation for Tuareg mode")
 | 
				
			||||||
 | 
					  (autoload 'ocp-indent-caml-mode-setup "ocp-indent" "Improved indentation for Caml mode")
 | 
				
			||||||
 | 
					  (add-hook 'tuareg-mode-hook 'ocp-setup-indent t)
 | 
				
			||||||
 | 
					  (add-hook 'caml-mode-hook 'ocp-indent-caml-mode-setup  t))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-ocp-index ()
 | 
				
			||||||
 | 
					  (autoload 'ocp-index-mode "ocp-index" "OCaml code browsing, documentation and completion based on build artefacts")
 | 
				
			||||||
 | 
					  (opam-setup-add-ocaml-hook 'ocp-index-mode))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-merlin ()
 | 
				
			||||||
 | 
					  (opam-setup-complete)
 | 
				
			||||||
 | 
					  (require 'merlin)
 | 
				
			||||||
 | 
					  (opam-setup-add-ocaml-hook 'merlin-mode)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  (defcustom ocp-index-use-auto-complete nil
 | 
				
			||||||
 | 
					    "Use auto-complete with ocp-index (disabled by default by opam-user-setup because merlin is in use)"
 | 
				
			||||||
 | 
					    :group 'ocp_index)
 | 
				
			||||||
 | 
					  (defcustom merlin-ac-setup 'easy
 | 
				
			||||||
 | 
					    "Use auto-complete with merlin (enabled by default by opam-user-setup)"
 | 
				
			||||||
 | 
					    :group 'merlin-ac)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  ;; So you can do it on a mac, where `C-<up>` and `C-<down>` are used
 | 
				
			||||||
 | 
					  ;; by spaces.
 | 
				
			||||||
 | 
					  (define-key merlin-mode-map
 | 
				
			||||||
 | 
					    (kbd "C-c <up>") 'merlin-type-enclosing-go-up)
 | 
				
			||||||
 | 
					  (define-key merlin-mode-map
 | 
				
			||||||
 | 
					    (kbd "C-c <down>") 'merlin-type-enclosing-go-down)
 | 
				
			||||||
 | 
					  (set-face-background 'merlin-type-face "skyblue"))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-setup-utop ()
 | 
				
			||||||
 | 
					  (autoload 'utop "utop" "Toplevel for OCaml" t)
 | 
				
			||||||
 | 
					  (autoload 'utop-minor-mode "utop" "Minor mode for utop" t)
 | 
				
			||||||
 | 
					  (add-hook 'tuareg-mode-hook 'utop-minor-mode))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defvar opam-tools
 | 
				
			||||||
 | 
					  '(("tuareg" . opam-setup-tuareg)
 | 
				
			||||||
 | 
					    ("ocp-indent" . opam-setup-ocp-indent)
 | 
				
			||||||
 | 
					    ("ocp-index" . opam-setup-ocp-index)
 | 
				
			||||||
 | 
					    ("merlin" . opam-setup-merlin)
 | 
				
			||||||
 | 
					    ("utop" . opam-setup-utop)))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-detect-installed-tools ()
 | 
				
			||||||
 | 
					  (let*
 | 
				
			||||||
 | 
					      ((command "opam list --installed --short --safe --color=never")
 | 
				
			||||||
 | 
					       (names (mapcar 'car opam-tools))
 | 
				
			||||||
 | 
					       (command-string (mapconcat 'identity (cons command names) " "))
 | 
				
			||||||
 | 
					       (reply (opam-shell-command-to-string command-string)))
 | 
				
			||||||
 | 
					    (when reply (split-string reply))))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defvar opam-tools-installed (opam-detect-installed-tools))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(defun opam-auto-tools-setup ()
 | 
				
			||||||
 | 
					  (interactive)
 | 
				
			||||||
 | 
					  (dolist (tool opam-tools)
 | 
				
			||||||
 | 
					    (when (member (car tool) opam-tools-installed)
 | 
				
			||||||
 | 
					     (funcall (symbol-function (cdr tool))))))
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					(opam-auto-tools-setup)
 | 
				
			||||||
 | 
					;; ## end of OPAM user-setup addition for emacs / base ## keep this line
 | 
				
			||||||
 | 
					;; ## added by OPAM user-setup for emacs / tuareg ## 02c044af5abd4321e32578768beeca77 ## you can edit, but keep this line
 | 
				
			||||||
 | 
					;; Set to autoload tuareg from its original switch when not found in current
 | 
				
			||||||
 | 
					;; switch (don't load tuareg-site-file as it adds unwanted load-paths)
 | 
				
			||||||
 | 
					(defun opam-tuareg-autoload (fct file doc args)
 | 
				
			||||||
 | 
					  (let ((load-path (cons "/usr/local/google/home/wpcarro/.opam/4.08.0/share/emacs/site-lisp" load-path)))
 | 
				
			||||||
 | 
					    (load file))
 | 
				
			||||||
 | 
					  (apply fct args))
 | 
				
			||||||
 | 
					(when (not (member "tuareg" opam-tools-installed))
 | 
				
			||||||
 | 
					  (defun tuareg-mode (&rest args)
 | 
				
			||||||
 | 
					    (opam-tuareg-autoload 'tuareg-mode "tuareg" "Major mode for editing OCaml code" args))
 | 
				
			||||||
 | 
					  (defun tuareg-run-ocaml (&rest args)
 | 
				
			||||||
 | 
					    (opam-tuareg-autoload 'tuareg-run-ocaml "tuareg" "Run an OCaml toplevel process" args))
 | 
				
			||||||
 | 
					  (defun ocamldebug (&rest args)
 | 
				
			||||||
 | 
					    (opam-tuareg-autoload 'ocamldebug "ocamldebug" "Run the OCaml debugger" args))
 | 
				
			||||||
 | 
					  (defalias 'run-ocaml 'tuareg-run-ocaml)
 | 
				
			||||||
 | 
					  (defalias 'camldebug 'ocamldebug)
 | 
				
			||||||
 | 
					  (add-to-list 'auto-mode-alist '("\\.ml[iylp]?\\'" . tuareg-mode))
 | 
				
			||||||
 | 
					  (add-to-list 'auto-mode-alist '("\\.eliomi?\\'" . tuareg-mode))
 | 
				
			||||||
 | 
					  (add-to-list 'interpreter-mode-alist '("ocamlrun" . tuareg-mode))
 | 
				
			||||||
 | 
					  (add-to-list 'interpreter-mode-alist '("ocaml" . tuareg-mode))
 | 
				
			||||||
 | 
					  (dolist (ext '(".cmo" ".cmx" ".cma" ".cmxa" ".cmxs" ".cmt" ".cmti" ".cmi" ".annot"))
 | 
				
			||||||
 | 
					    (add-to-list 'completion-ignored-extensions ext)))
 | 
				
			||||||
 | 
					;; ## end of OPAM user-setup addition for emacs / tuareg ## keep this line
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					("~/Dropbox/programming/data_structures_and_algorithms/" "~/Dropbox/dotfiles/" "~/Dropbox/ide/" "~/Dropbox/programming/tazjins-dotfiles/" "~/Dropbox/programming/tablecloth/" "~/Dropbox/programming/ngs/" "~/Dropbox/programming/" "~/.tmux/plugins/tmux-onedark-theme/" "~/Dropbox/programming/lispyville/" "~/Dropbox/programming/i3-quickterm/" "~/Dropbox/programming/db_cli/" "~/Dropbox/programming/clipmenu/" "~/Dropbox/ide-server/" "~/Dropbox/st/" "~/Dropbox/dwm/" "~/Dropbox/ide-server-stack/" "~/Dropbox/programming/programming/powerlisp/" "~/Dropbox/programming/nixery/" "/google/src/cloud/wpcarro/ac-skeleton/")
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					("~/Dropbox/dotfiles/" "~/Dropbox/programming/data_structures_and_algorithms/" "~/Dropbox/ide/" "~/Dropbox/programming/tazjins-dotfiles/" "~/Dropbox/programming/tablecloth/" "~/Dropbox/programming/ngs/" "~/Dropbox/programming/" "~/.tmux/plugins/tmux-onedark-theme/" "~/Dropbox/programming/lispyville/" "~/Dropbox/programming/i3-quickterm/" "~/Dropbox/programming/db_cli/" "~/Dropbox/programming/clipmenu/" "~/Dropbox/ide-server/" "~/Dropbox/st/" "~/Dropbox/dwm/" "~/Dropbox/ide-server-stack/" "~/Dropbox/programming/programming/powerlisp/" "~/Dropbox/programming/nixery/")
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.emacs.d/snippets/c-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.emacs.d/snippets/c-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,8 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Function
 | 
				
			||||||
 | 
					# key: fn
 | 
				
			||||||
 | 
					# expand-env: ((yas-indent-line 'fixed))
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					(defun $1 ($2)
 | 
				
			||||||
 | 
					  "$3"
 | 
				
			||||||
 | 
					  $4)
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,7 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Header
 | 
				
			||||||
 | 
					# key: hdr
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 | 
				
			||||||
 | 
					;; $1
 | 
				
			||||||
 | 
					;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,7 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Library header
 | 
				
			||||||
 | 
					# key: lib
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 | 
				
			||||||
 | 
					;; Library
 | 
				
			||||||
 | 
					;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.emacs.d/snippets/html-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.emacs.d/snippets/html-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.emacs.d/snippets/java-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.emacs.d/snippets/java-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.emacs.d/snippets/nix-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.emacs.d/snippets/nix-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.emacs.d/snippets/org-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.emacs.d/snippets/org-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										7
									
								
								configs/shared/.emacs.d/snippets/python-mode/header
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								configs/shared/.emacs.d/snippets/python-mode/header
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,7 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Header
 | 
				
			||||||
 | 
					# key: hdr
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					################################################################################
 | 
				
			||||||
 | 
					# $1
 | 
				
			||||||
 | 
					################################################################################
 | 
				
			||||||
							
								
								
									
										6
									
								
								configs/shared/.emacs.d/snippets/python-mode/init
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										6
									
								
								configs/shared/.emacs.d/snippets/python-mode/init
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,6 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: dunder init
 | 
				
			||||||
 | 
					# key: ctor
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					def __init__(self$1):
 | 
				
			||||||
 | 
					    $2
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										5
									
								
								configs/shared/.emacs.d/snippets/racket-mode/function
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								configs/shared/.emacs.d/snippets/racket-mode/function
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,5 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Function
 | 
				
			||||||
 | 
					# key: fn
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					(define ($1) $2)
 | 
				
			||||||
							
								
								
									
										5
									
								
								configs/shared/.emacs.d/snippets/racket-mode/lambda
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								configs/shared/.emacs.d/snippets/racket-mode/lambda
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,5 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Lambda function
 | 
				
			||||||
 | 
					# key: ld
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					(λ ($1) $2)
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,5 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Lambda symbol
 | 
				
			||||||
 | 
					# key: l
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					λ
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
							
								
								
									
										7
									
								
								configs/shared/.emacs.d/snippets/reason-mode/function
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								configs/shared/.emacs.d/snippets/reason-mode/function
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,7 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Function
 | 
				
			||||||
 | 
					# key: fn
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					let $1 = (~$2:$3) => {
 | 
				
			||||||
 | 
					  $4
 | 
				
			||||||
 | 
					};
 | 
				
			||||||
							
								
								
									
										7
									
								
								configs/shared/.emacs.d/snippets/reason-mode/switch
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								configs/shared/.emacs.d/snippets/reason-mode/switch
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1,7 @@
 | 
				
			||||||
 | 
					# -*- mode: snippet -*-
 | 
				
			||||||
 | 
					# name: Switch statement
 | 
				
			||||||
 | 
					# key: sw
 | 
				
			||||||
 | 
					# --
 | 
				
			||||||
 | 
					switch ($1) {
 | 
				
			||||||
 | 
					| $2 =>
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
							
								
								
									
										1
									
								
								configs/shared/.emacs.d/snippets/rjsx-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										1
									
								
								configs/shared/.emacs.d/snippets/rjsx-mode/.yas-parents
									
										
									
									
									
										Normal file
									
								
							| 
						 | 
					@ -0,0 +1 @@
 | 
				
			||||||
 | 
					text-mode
 | 
				
			||||||
Some files were not shown because too many files have changed in this diff Show more
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue