mirror of
https://github.com/theniceboy/.config.git
synced 2025-12-26 14:44:57 +08:00
new stuff
This commit is contained in:
parent
b0b4b99091
commit
a869686745
8 changed files with 170 additions and 47 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -21,3 +21,4 @@
|
|||
!/llpp.conf
|
||||
!/README.md
|
||||
!/vimium-options.json
|
||||
!/zsh
|
||||
|
|
|
|||
|
|
@ -102,19 +102,19 @@ tabspaces: 8
|
|||
font:
|
||||
# The normal (roman) font face to use.
|
||||
normal:
|
||||
family: MesloLGSDZ
|
||||
family: Source Code Pro
|
||||
# Style can be specified to pick a specific face.
|
||||
style: Regular
|
||||
# style: Regular
|
||||
|
||||
# The bold font face
|
||||
bold:
|
||||
family: MesloLGSDZ
|
||||
family: Source Code Pro
|
||||
# Style can be specified to pick a specific face.
|
||||
# style: Bold
|
||||
|
||||
# The italic font face
|
||||
italic:
|
||||
family: MesloLGSDZ
|
||||
family: Source Code Pro
|
||||
# Style can be specified to pick a specific face.
|
||||
# style: Italic
|
||||
|
||||
|
|
|
|||
4
fish/functions/ms.fish
Normal file
4
fish/functions/ms.fish
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
# Defined in - @ line 1
|
||||
function ms --description 'alias ms mailsync'
|
||||
mailsync $argv;
|
||||
end
|
||||
4
fish/functions/mt.fish
Normal file
4
fish/functions/mt.fish
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
# Defined in - @ line 1
|
||||
function mt --description 'alias mt neomutt'
|
||||
neomutt $argv;
|
||||
end
|
||||
51
i3/config
51
i3/config
|
|
@ -161,6 +161,8 @@ set $ws5 5
|
|||
set $ws6 6
|
||||
set $ws7 7
|
||||
set $ws8 8
|
||||
set $ws9 9
|
||||
set $ws0 10
|
||||
|
||||
# switch to workspace
|
||||
bindsym $mod+1 workspace $ws1
|
||||
|
|
@ -171,6 +173,8 @@ 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 $ws0
|
||||
|
||||
# Move focused container to workspace
|
||||
bindsym $mod+Ctrl+1 move container to workspace $ws1
|
||||
|
|
@ -181,6 +185,8 @@ 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 $ws0
|
||||
|
||||
# Move to workspace with focused container
|
||||
bindsym $mod+Shift+1 move container to workspace $ws1; workspace $ws1
|
||||
|
|
@ -191,6 +197,23 @@ 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 $ws0; workspace $ws0
|
||||
|
||||
set $monitor1 DP1
|
||||
set $monitor2 HDMI1
|
||||
workspace 0 output $monitor1
|
||||
workspace 1 output $monitor1
|
||||
workspace 2 output $monitor1
|
||||
workspace 3 output $monitor1
|
||||
workspace 4 output $monitor2
|
||||
workspace 5 output $monitor2
|
||||
workspace 6 output $monitor2
|
||||
workspace 7 output $monitor2
|
||||
workspace 8 output $monitor2
|
||||
workspace 9 output $monitor2
|
||||
|
||||
|
||||
|
||||
# Open applications on specific workspaces
|
||||
# assign [class="Thunderbird"] $ws1
|
||||
|
|
@ -239,21 +262,21 @@ bindsym $mod+Shift+p restart
|
|||
bindsym $mod+Shift+f exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -b 'Yes, exit i3' 'i3-msg exit'"
|
||||
|
||||
# Set shut down, restart and locking features
|
||||
bindsym $mod+0 mode "$mode_system"
|
||||
set $mode_system (l)ock, (e)xit, switch_(u)ser, (s)uspend, (h)ibernate, (r)eboot, (Shift+s)hutdown
|
||||
mode "$mode_system" {
|
||||
bindsym l exec --no-startup-id i3exit lock, mode "default"
|
||||
bindsym s exec --no-startup-id i3exit suspend, mode "default"
|
||||
bindsym u exec --no-startup-id i3exit switch_user, mode "default"
|
||||
bindsym e exec --no-startup-id i3exit logout, mode "default"
|
||||
bindsym h exec --no-startup-id i3exit hibernate, mode "default"
|
||||
bindsym r exec --no-startup-id i3exit reboot, mode "default"
|
||||
bindsym Shift+s exec --no-startup-id i3exit shutdown, mode "default"
|
||||
#bindsym $mod+0 mode "$mode_system"
|
||||
#set $mode_system (l)ock, (e)xit, switch_(u)ser, (s)uspend, (h)ibernate, (r)eboot, (Shift+s)hutdown
|
||||
#mode "$mode_system" {
|
||||
#bindsym l exec --no-startup-id i3exit lock, mode "default"
|
||||
#bindsym s exec --no-startup-id i3exit suspend, mode "default"
|
||||
#bindsym u exec --no-startup-id i3exit switch_user, mode "default"
|
||||
#bindsym e exec --no-startup-id i3exit logout, mode "default"
|
||||
#bindsym h exec --no-startup-id i3exit hibernate, mode "default"
|
||||
#bindsym r exec --no-startup-id i3exit reboot, mode "default"
|
||||
#bindsym Shift+s exec --no-startup-id i3exit shutdown, mode "default"
|
||||
|
||||
# exit system mode: "Enter" or "Escape"
|
||||
bindsym Return mode "default"
|
||||
bindsym Escape mode "default"
|
||||
}
|
||||
## exit system mode: "Enter" or "Escape"
|
||||
#bindsym Return mode "default"
|
||||
#bindsym Escape mode "default"
|
||||
#}
|
||||
|
||||
# Resize window (you can also use the mouse for that)
|
||||
bindsym $mod+p mode "resize"
|
||||
|
|
|
|||
|
|
@ -296,9 +296,6 @@ alias travel scout -aefklst
|
|||
# == Define keys for the browser
|
||||
# ===================================================================
|
||||
|
||||
# Quick edit rc
|
||||
map gc chain shell vim -p ~/.config/ranger/rc.conf; source ~/.config/ranger/rc.conf
|
||||
|
||||
# Basic
|
||||
map q quit
|
||||
map Q quitall
|
||||
|
|
@ -333,7 +330,10 @@ map gff cd ~/.config/fish
|
|||
map gfi cd ~/.config/i3
|
||||
map gfr cd ~/.config/ranger
|
||||
map gfn cd ~/.config/nvim
|
||||
map gfz cd ~/.config/zsh
|
||||
map ge cd /etc
|
||||
map gU cd /usr
|
||||
map gub cd /usr/bin
|
||||
map gus cd /usr/share
|
||||
map guf cd /usr/share/fonts
|
||||
map gud cd /usr/share/doc
|
||||
|
|
@ -342,6 +342,8 @@ map gv cd /var
|
|||
map gm cd /run/media
|
||||
map gM cd /mnt
|
||||
map gr cd /
|
||||
map gG cd ~/go/src
|
||||
map gc cd ~/Github/CalPoly
|
||||
|
||||
|
||||
# In case you work on a keyboard with dvorak layout
|
||||
|
|
|
|||
|
|
@ -54,32 +54,33 @@
|
|||
# Rarely installed browsers get higher priority; It is assumed that if you
|
||||
# install a rare browser, you probably use it. Firefox/konqueror/w3m on the
|
||||
# other hand are often only installed as fallback browsers.
|
||||
ext x?html?, has surf, X, flag f = surf -- file://"$1"
|
||||
ext x?html?, has vimprobable, X, flag f = vimprobable -- "$@"
|
||||
ext x?html?, has vimprobable2, X, flag f = vimprobable2 -- "$@"
|
||||
ext x?html?, has qutebrowser, X, flag f = qutebrowser -- "$@"
|
||||
ext x?html?, has dwb, X, flag f = dwb -- "$@"
|
||||
ext x?html?, has jumanji, X, flag f = jumanji -- "$@"
|
||||
ext x?html?, has luakit, X, flag f = luakit -- "$@"
|
||||
ext x?html?, has uzbl, X, flag f = uzbl -- "$@"
|
||||
ext x?html?, has uzbl-tabbed, X, flag f = uzbl-tabbed -- "$@"
|
||||
ext x?html?, has uzbl-browser, X, flag f = uzbl-browser -- "$@"
|
||||
ext x?html?, has uzbl-core, X, flag f = uzbl-core -- "$@"
|
||||
ext x?html?, has midori, X, flag f = midori -- "$@"
|
||||
ext x?html?, has chromium-browser, X, flag f = chromium-browser -- "$@"
|
||||
ext x?html?, has chromium, X, flag f = chromium -- "$@"
|
||||
ext x?html?, has google-chrome, X, flag f = google-chrome -- "$@"
|
||||
ext x?html?, has opera, X, flag f = opera -- "$@"
|
||||
ext x?html?, has firefox, X, flag f = firefox -- "$@"
|
||||
ext x?html?, has seamonkey, X, flag f = seamonkey -- "$@"
|
||||
ext x?html?, has iceweasel, X, flag f = iceweasel -- "$@"
|
||||
ext x?html?, has epiphany, X, flag f = epiphany -- "$@"
|
||||
ext x?html?, has konqueror, X, flag f = konqueror -- "$@"
|
||||
ext x?html?, has elinks, terminal = elinks "$@"
|
||||
ext x?html?, has links2, terminal = links2 "$@"
|
||||
ext x?html?, has links, terminal = links "$@"
|
||||
ext x?html?, has lynx, terminal = lynx -- "$@"
|
||||
ext x?html?, has w3m, terminal = w3m "$@"
|
||||
ext html = neovim "$@"
|
||||
#ext x?html?, has surf, X, flag f = surf -- file://"$1"
|
||||
#ext x?html?, has vimprobable, X, flag f = vimprobable -- "$@"
|
||||
#ext x?html?, has vimprobable2, X, flag f = vimprobable2 -- "$@"
|
||||
#ext x?html?, has qutebrowser, X, flag f = qutebrowser -- "$@"
|
||||
#ext x?html?, has dwb, X, flag f = dwb -- "$@"
|
||||
#ext x?html?, has jumanji, X, flag f = jumanji -- "$@"
|
||||
#ext x?html?, has luakit, X, flag f = luakit -- "$@"
|
||||
#ext x?html?, has uzbl, X, flag f = uzbl -- "$@"
|
||||
#ext x?html?, has uzbl-tabbed, X, flag f = uzbl-tabbed -- "$@"
|
||||
#ext x?html?, has uzbl-browser, X, flag f = uzbl-browser -- "$@"
|
||||
#ext x?html?, has uzbl-core, X, flag f = uzbl-core -- "$@"
|
||||
#ext x?html?, has midori, X, flag f = midori -- "$@"
|
||||
#ext x?html?, has chromium-browser, X, flag f = chromium-browser -- "$@"
|
||||
#ext x?html?, has chromium, X, flag f = chromium -- "$@"
|
||||
#ext x?html?, has google-chrome, X, flag f = google-chrome -- "$@"
|
||||
#ext x?html?, has opera, X, flag f = opera -- "$@"
|
||||
#ext x?html?, has firefox, X, flag f = firefox -- "$@"
|
||||
#ext x?html?, has seamonkey, X, flag f = seamonkey -- "$@"
|
||||
#ext x?html?, has iceweasel, X, flag f = iceweasel -- "$@"
|
||||
#ext x?html?, has epiphany, X, flag f = epiphany -- "$@"
|
||||
#ext x?html?, has konqueror, X, flag f = konqueror -- "$@"
|
||||
#ext x?html?, has elinks, terminal = elinks "$@"
|
||||
#ext x?html?, has links2, terminal = links2 "$@"
|
||||
#ext x?html?, has links, terminal = links "$@"
|
||||
#ext x?html?, has lynx, terminal = lynx -- "$@"
|
||||
#ext x?html?, has w3m, terminal = w3m "$@"
|
||||
|
||||
#-------------------------------------------
|
||||
# Misc
|
||||
|
|
@ -101,6 +102,7 @@ name ^[mM]akefile$ = make
|
|||
# Code
|
||||
#-------------------------------------------
|
||||
ext py = python -- "$1"
|
||||
ext go = nvim "$1"
|
||||
ext pl = perl -- "$1"
|
||||
ext rb = ruby -- "$1"
|
||||
ext js = node -- "$1"
|
||||
|
|
|
|||
87
zsh/aliasrc
Normal file
87
zsh/aliasrc
Normal file
|
|
@ -0,0 +1,87 @@
|
|||
|
||||
## Enable colors and change prompt:
|
||||
#autoload -U colors && colors
|
||||
#PS1="%B%{$fg[red]%}[%{$fg[yellow]%}%n%{$fg[green]%}@%{$fg[blue]%}%M %{$fg[magenta]%}%~%{$fg[red]%}]%{$reset_color%}$%b "
|
||||
|
||||
## History in cache directory:
|
||||
#HISTSIZE=10000
|
||||
#SAVEHIST=10000
|
||||
#HISTFILE=~/.cache/zsh/history
|
||||
|
||||
## Basic auto/tab complete:
|
||||
#autoload -U compinit
|
||||
#zstyle ':completion:*' menu select
|
||||
#zmodload zsh/complist
|
||||
#compinit
|
||||
#_comp_options+=(globdots) # Include hidden files.
|
||||
|
||||
## vi mode
|
||||
#bindkey -v
|
||||
#export KEYTIMEOUT=1
|
||||
|
||||
## Use vim keys in tab complete menu:
|
||||
#bindkey -M menuselect 'n' vi-backward-char
|
||||
#bindkey -M menuselect 'u' vi-up-line-or-history
|
||||
#bindkey -M menuselect 'i' vi-forward-char
|
||||
#bindkey -M menuselect 'e' vi-down-line-or-history
|
||||
#bindkey -v '^?' backward-delete-char
|
||||
|
||||
## Change cursor shape for different vi modes.
|
||||
#function zle-keymap-select {
|
||||
#if [[ ${KEYMAP} == vicmd ]] ||
|
||||
#[[ $1 = 'block' ]]; then
|
||||
#echo -ne '\e[1 q'
|
||||
#elif [[ ${KEYMAP} == main ]] ||
|
||||
#[[ ${KEYMAP} == viins ]] ||
|
||||
#[[ ${KEYMAP} = '' ]] ||
|
||||
#[[ $1 = 'beam' ]]; then
|
||||
#echo -ne '\e[5 q'
|
||||
#fi
|
||||
#}
|
||||
#zle -N zle-keymap-select
|
||||
#zle-line-init() {
|
||||
#zle -K viins # initiate `vi insert` as keymap (can be removed if `bindkey -V` has been set elsewhere)
|
||||
#echo -ne "\e[5 q"
|
||||
#}
|
||||
#zle -N zle-line-init
|
||||
#echo -ne '\e[5 q' # Use beam shape cursor on startup.
|
||||
#preexec() { echo -ne '\e[5 q' ;} # Use beam shape cursor for each new prompt.
|
||||
|
||||
## Use lf to switch directories and bind it to ctrl-o
|
||||
#lfcd () {
|
||||
#tmp="$(mktemp)"
|
||||
#lf -last-dir-path="$tmp" "$@"
|
||||
#if [ -f "$tmp" ]; then
|
||||
#dir="$(cat "$tmp")"
|
||||
#rm -f "$tmp"
|
||||
#[ -d "$dir" ] && [ "$dir" != "$(pwd)" ] && cd "$dir"
|
||||
#fi
|
||||
#}
|
||||
#bindkey -s '^o' 'lfcd\n'
|
||||
|
||||
## Edit line in vim with ctrl-e:
|
||||
#autoload edit-command-line; zle -N edit-command-line
|
||||
#bindkey '^e' edit-command-line
|
||||
|
||||
# Load aliases and shortcuts if existent.
|
||||
#[ -f "$HOME/.config/shortcutrc" ] && source "$HOME/.config/shortcutrc"
|
||||
#[ -f "$HOME/.config/aliasrc" ] && source "$HOME/.config/aliasrc"
|
||||
|
||||
#alias av='source venv/bin/activate.fish'
|
||||
alias c='clear'
|
||||
alias cdiff='colordiff'
|
||||
alias cs='cowsay'
|
||||
#alias dv='deactivate'
|
||||
alias gc='git config credential.helper store'
|
||||
alias ipy='ipython'
|
||||
alias l='ls -la'
|
||||
alias lg='lazygit'
|
||||
alias ms='mailsync'
|
||||
alias mt='neomutt'
|
||||
alias nv='nvim'
|
||||
alias ra='ranger'
|
||||
alias s='neofetch'
|
||||
alias sra='sudo -E ranger'
|
||||
alias sudo='sudo -E'
|
||||
alias vim='nvim'
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue