more config
This commit is contained in:
parent
980fb49431
commit
ceda3aa738
10 changed files with 647 additions and 2061 deletions
|
|
@ -1,4 +1,12 @@
|
|||
# .bash_profile
|
||||
|
||||
#
|
||||
# ~/.bash_profile
|
||||
#
|
||||
# Get the aliases and functions
|
||||
[ -f $HOME/.bashrc ] && . $HOME/.bashrc
|
||||
[[ -f ~/.bashrc ]] && . ~/.bashrc
|
||||
|
||||
export XDG_CONFIG_HOME="$HOME/.config"
|
||||
#export DISPLAY=:0
|
||||
export BROWSER=firefox
|
||||
export EDITOR=vim
|
||||
export TERM=screen-256color
|
||||
|
|
|
|||
|
|
@ -7,6 +7,7 @@ alias ls='ls --color=auto'
|
|||
alias vlime='sbcl --load ~/.vim/plugins/vlime/lisp/start-vlime.lisp'
|
||||
PS1='[\u@\h \W]\$ '
|
||||
|
||||
alias screenfetch='clear && screenfetch -t'
|
||||
export DISPLAY=:0
|
||||
export LIBGL_ALWAYS_INDIRECT=1
|
||||
export FZF_DEFAULT_COMMAD="find -L"
|
||||
|
|
|
|||
26
mpd/mpd.conf
Normal file
26
mpd/mpd.conf
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
db_file "~/.config/mpd/database"
|
||||
log_file "~/.config/mpd/log"
|
||||
music_directory "~/Music"
|
||||
playlist_directory "~/.config/mpd/playlists"
|
||||
pid_file "~/.config/mpd/pid"
|
||||
state_file "~/.config/mpd/state"
|
||||
sticker_file "~/.config/mpd/sticker.sql"
|
||||
|
||||
auto_update "yes"
|
||||
|
||||
bind_to_address "127.0.0.1"
|
||||
restore_paused "yes"
|
||||
max_output_buffer_size "16384"
|
||||
|
||||
audio_output {
|
||||
type "alsa"
|
||||
name "alsa for audio soundcard"
|
||||
mixer_type "software"
|
||||
}
|
||||
|
||||
audio_output {
|
||||
type "fifo"
|
||||
name "toggle_visualizer"
|
||||
path "/tmp/mpd.fifo"
|
||||
format "44100:16:2"
|
||||
}
|
||||
480
ncmpcpp/bindings
Normal file
480
ncmpcpp/bindings
Normal file
|
|
@ -0,0 +1,480 @@
|
|||
##############################################################
|
||||
## This is the example bindings file. Copy it to ##
|
||||
## ~/.ncmpcpp/bindings or $XDG_CONFIG_HOME/ncmpcpp/bindings ##
|
||||
## and set up your preferences ##
|
||||
##############################################################
|
||||
#
|
||||
#def_key "mouse"
|
||||
# mouse_event
|
||||
#
|
||||
#def_key "up"
|
||||
# scroll_up
|
||||
#
|
||||
#def_key "shift-up"
|
||||
# select_item
|
||||
# scroll_up
|
||||
#
|
||||
#def_key "down"
|
||||
# scroll_down
|
||||
#
|
||||
#def_key "shift-down"
|
||||
# select_item
|
||||
# scroll_down
|
||||
#
|
||||
#def_key "["
|
||||
# scroll_up_album
|
||||
#
|
||||
#def_key "]"
|
||||
# scroll_down_album
|
||||
#
|
||||
#def_key "{"
|
||||
# scroll_up_artist
|
||||
#
|
||||
#def_key "}"
|
||||
# scroll_down_artist
|
||||
#
|
||||
#def_key "page_up"
|
||||
# page_up
|
||||
#
|
||||
#def_key "page_down"
|
||||
# page_down
|
||||
#
|
||||
#def_key "home"
|
||||
# move_home
|
||||
#
|
||||
#def_key "end"
|
||||
# move_end
|
||||
#
|
||||
#def_key "insert"
|
||||
# select_item
|
||||
#
|
||||
#def_key "enter"
|
||||
# enter_directory
|
||||
#
|
||||
#def_key "enter"
|
||||
# toggle_output
|
||||
#
|
||||
#def_key "enter"
|
||||
# run_action
|
||||
#
|
||||
def_key "enter"
|
||||
play_item
|
||||
#
|
||||
#def_key "space"
|
||||
# add_item_to_playlist
|
||||
#
|
||||
#def_key "space"
|
||||
# toggle_lyrics_update_on_song_change
|
||||
#
|
||||
#def_key "space"
|
||||
# toggle_visualization_type
|
||||
#
|
||||
#def_key "delete"
|
||||
# delete_playlist_items
|
||||
#
|
||||
#def_key "delete"
|
||||
# delete_browser_items
|
||||
#
|
||||
#def_key "delete"
|
||||
# delete_stored_playlist
|
||||
#
|
||||
#def_key "right"
|
||||
# next_column
|
||||
#
|
||||
#def_key "right"
|
||||
# slave_screen
|
||||
#
|
||||
#def_key "right"
|
||||
# volume_up
|
||||
#
|
||||
#def_key "+"
|
||||
# volume_up
|
||||
#
|
||||
#def_key "left"
|
||||
# previous_column
|
||||
#
|
||||
#def_key "left"
|
||||
# master_screen
|
||||
#
|
||||
#def_key "left"
|
||||
# volume_down
|
||||
#
|
||||
#def_key "-"
|
||||
# volume_down
|
||||
#
|
||||
#def_key ":"
|
||||
# execute_command
|
||||
#
|
||||
#def_key "tab"
|
||||
# next_screen
|
||||
#
|
||||
#def_key "shift-tab"
|
||||
# previous_screen
|
||||
#
|
||||
#def_key "f1"
|
||||
# show_help
|
||||
#
|
||||
#def_key "1"
|
||||
# show_playlist
|
||||
#
|
||||
#def_key "2"
|
||||
# show_browser
|
||||
#
|
||||
#def_key "2"
|
||||
# change_browse_mode
|
||||
#
|
||||
#def_key "3"
|
||||
# show_search_engine
|
||||
#
|
||||
#def_key "3"
|
||||
# reset_search_engine
|
||||
#
|
||||
#def_key "4"
|
||||
# show_media_library
|
||||
#
|
||||
#def_key "4"
|
||||
# toggle_media_library_columns_mode
|
||||
#
|
||||
#def_key "5"
|
||||
# show_playlist_editor
|
||||
#
|
||||
#def_key "6"
|
||||
# show_tag_editor
|
||||
#
|
||||
#def_key "7"
|
||||
# show_outputs
|
||||
#
|
||||
#def_key "8"
|
||||
# show_visualizer
|
||||
#
|
||||
#def_key "="
|
||||
# show_clock
|
||||
#
|
||||
#def_key "@"
|
||||
# show_server_info
|
||||
#
|
||||
#def_key "s"
|
||||
# stop
|
||||
#
|
||||
#def_key "p"
|
||||
# pause
|
||||
#
|
||||
#def_key ">"
|
||||
# next
|
||||
#
|
||||
#def_key "<"
|
||||
# previous
|
||||
#
|
||||
#def_key "ctrl-h"
|
||||
# jump_to_parent_directory
|
||||
#
|
||||
#def_key "ctrl-h"
|
||||
# replay_song
|
||||
#
|
||||
#def_key "backspace"
|
||||
# jump_to_parent_directory
|
||||
#
|
||||
#def_key "backspace"
|
||||
# replay_song
|
||||
#
|
||||
#def_key "f"
|
||||
# seek_forward
|
||||
#
|
||||
#def_key "b"
|
||||
# seek_backward
|
||||
#
|
||||
#def_key "r"
|
||||
# toggle_repeat
|
||||
#
|
||||
#def_key "z"
|
||||
# toggle_random
|
||||
#
|
||||
#def_key "y"
|
||||
# save_tag_changes
|
||||
#
|
||||
#def_key "y"
|
||||
# start_searching
|
||||
#
|
||||
#def_key "y"
|
||||
# toggle_single
|
||||
#
|
||||
#def_key "R"
|
||||
# toggle_consume
|
||||
#
|
||||
#def_key "Y"
|
||||
# toggle_replay_gain_mode
|
||||
#
|
||||
#def_key "T"
|
||||
# toggle_add_mode
|
||||
#
|
||||
#def_key "|"
|
||||
# toggle_mouse
|
||||
#
|
||||
#def_key "#"
|
||||
# toggle_bitrate_visibility
|
||||
#
|
||||
#def_key "Z"
|
||||
# shuffle
|
||||
#
|
||||
#def_key "x"
|
||||
# toggle_crossfade
|
||||
#
|
||||
#def_key "X"
|
||||
# set_crossfade
|
||||
#
|
||||
#def_key "u"
|
||||
# update_database
|
||||
#
|
||||
#def_key "ctrl-s"
|
||||
# sort_playlist
|
||||
#
|
||||
#def_key "ctrl-s"
|
||||
# toggle_browser_sort_mode
|
||||
#
|
||||
#def_key "ctrl-s"
|
||||
# toggle_media_library_sort_mode
|
||||
#
|
||||
#def_key "ctrl-r"
|
||||
# reverse_playlist
|
||||
#
|
||||
#def_key "ctrl-f"
|
||||
# apply_filter
|
||||
#
|
||||
#def_key "ctrl-_"
|
||||
# select_found_items
|
||||
#
|
||||
#def_key "/"
|
||||
# find
|
||||
#
|
||||
#def_key "/"
|
||||
# find_item_forward
|
||||
#
|
||||
#def_key "?"
|
||||
# find
|
||||
#
|
||||
#def_key "?"
|
||||
# find_item_backward
|
||||
#
|
||||
#def_key "."
|
||||
# next_found_item
|
||||
#
|
||||
#def_key ","
|
||||
# previous_found_item
|
||||
#
|
||||
#def_key "w"
|
||||
# toggle_find_mode
|
||||
#
|
||||
#def_key "e"
|
||||
# edit_song
|
||||
#
|
||||
#def_key "e"
|
||||
# edit_library_tag
|
||||
#
|
||||
#def_key "e"
|
||||
# edit_library_album
|
||||
#
|
||||
#def_key "e"
|
||||
# edit_directory_name
|
||||
#
|
||||
#def_key "e"
|
||||
# edit_playlist_name
|
||||
#
|
||||
#def_key "e"
|
||||
# edit_lyrics
|
||||
#
|
||||
#def_key "i"
|
||||
# show_song_info
|
||||
#
|
||||
#def_key "I"
|
||||
# show_artist_info
|
||||
#
|
||||
#def_key "g"
|
||||
# jump_to_position_in_song
|
||||
#
|
||||
#def_key "l"
|
||||
# show_lyrics
|
||||
#
|
||||
#def_key "ctrl-v"
|
||||
# select_range
|
||||
#
|
||||
#def_key "v"
|
||||
# reverse_selection
|
||||
#
|
||||
#def_key "V"
|
||||
# remove_selection
|
||||
#
|
||||
#def_key "B"
|
||||
# select_album
|
||||
#
|
||||
#def_key "a"
|
||||
# add_selected_items
|
||||
#
|
||||
#def_key "c"
|
||||
# clear_playlist
|
||||
#
|
||||
#def_key "c"
|
||||
# clear_main_playlist
|
||||
#
|
||||
#def_key "C"
|
||||
# crop_playlist
|
||||
#
|
||||
#def_key "C"
|
||||
# crop_main_playlist
|
||||
#
|
||||
#def_key "m"
|
||||
# move_sort_order_up
|
||||
#
|
||||
#def_key "m"
|
||||
# move_selected_items_up
|
||||
#
|
||||
#def_key "n"
|
||||
# move_sort_order_down
|
||||
#
|
||||
#def_key "n"
|
||||
# move_selected_items_down
|
||||
#
|
||||
#def_key "M"
|
||||
# move_selected_items_to
|
||||
#
|
||||
#def_key "A"
|
||||
# add
|
||||
#
|
||||
#def_key "S"
|
||||
# save_playlist
|
||||
#
|
||||
#def_key "o"
|
||||
# jump_to_playing_song
|
||||
#
|
||||
#def_key "G"
|
||||
# jump_to_browser
|
||||
#
|
||||
#def_key "G"
|
||||
# jump_to_playlist_editor
|
||||
#
|
||||
#def_key "~"
|
||||
# jump_to_media_library
|
||||
#
|
||||
#def_key "E"
|
||||
# jump_to_tag_editor
|
||||
#
|
||||
#def_key "U"
|
||||
# toggle_playing_song_centering
|
||||
#
|
||||
#def_key "P"
|
||||
# toggle_display_mode
|
||||
#
|
||||
#def_key "\\"
|
||||
# toggle_interface
|
||||
#
|
||||
#def_key "!"
|
||||
# toggle_separators_between_albums
|
||||
#
|
||||
#def_key "L"
|
||||
# toggle_lyrics_fetcher
|
||||
#
|
||||
#def_key "F"
|
||||
# fetch_lyrics_in_background
|
||||
#
|
||||
#def_key "alt-l"
|
||||
# toggle_fetching_lyrics_in_background
|
||||
#
|
||||
#def_key "ctrl-l"
|
||||
# toggle_screen_lock
|
||||
#
|
||||
#def_key "`"
|
||||
# toggle_library_tag_type
|
||||
#
|
||||
#def_key "`"
|
||||
# refetch_lyrics
|
||||
#
|
||||
#def_key "`"
|
||||
# add_random_items
|
||||
#
|
||||
#def_key "ctrl-p"
|
||||
# set_selected_items_priority
|
||||
#
|
||||
#def_key "q"
|
||||
# quit
|
||||
#
|
||||
#
|
||||
#def_key "f"
|
||||
# find
|
||||
#def_key "f"
|
||||
# find_item_forward
|
||||
|
||||
def_key "+"
|
||||
show_clock
|
||||
def_key "="
|
||||
volume_up
|
||||
|
||||
def_key "j"
|
||||
scroll_down
|
||||
def_key "k"
|
||||
scroll_up
|
||||
|
||||
def_key "ctrl-u"
|
||||
page_up
|
||||
#push_characters "kkkkkkkkkkkkkkk"
|
||||
def_key "ctrl-d"
|
||||
page_down
|
||||
#push_characters "jjjjjjjjjjjjjjj"
|
||||
def_key "u"
|
||||
page_up
|
||||
#push_characters "kkkkkkkkkkkkkkk"
|
||||
def_key "d"
|
||||
page_down
|
||||
#push_characters "jjjjjjjjjjjjjjj"
|
||||
def_key "h"
|
||||
previous_column
|
||||
def_key "l"
|
||||
next_column
|
||||
|
||||
def_key "."
|
||||
show_lyrics
|
||||
|
||||
def_key "n"
|
||||
next_found_item
|
||||
def_key "N"
|
||||
previous_found_item
|
||||
|
||||
# not used but bound
|
||||
def_key "J"
|
||||
move_sort_order_down
|
||||
def_key "K"
|
||||
move_sort_order_up
|
||||
def_key "h"
|
||||
jump_to_parent_directory
|
||||
def_key "l"
|
||||
enter_directory
|
||||
def_key "l"
|
||||
run_action
|
||||
def_key "l"
|
||||
play_item
|
||||
def_key "m"
|
||||
show_media_library
|
||||
def_key "m"
|
||||
toggle_media_library_columns_mode
|
||||
def_key "t"
|
||||
show_tag_editor
|
||||
def_key "v"
|
||||
show_visualizer
|
||||
def_key "G"
|
||||
move_end
|
||||
def_key "g"
|
||||
move_home
|
||||
#jump_to_position_in_song
|
||||
def_key "U"
|
||||
update_database
|
||||
def_key "s"
|
||||
reset_search_engine
|
||||
def_key "s"
|
||||
show_search_engine
|
||||
def_key "f"
|
||||
show_browser
|
||||
def_key "f"
|
||||
change_browse_mode
|
||||
def_key "x"
|
||||
delete_playlist_items
|
||||
def_key "P"
|
||||
show_playlist
|
||||
|
||||
40
newsboat/config
Normal file
40
newsboat/config
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
browser qutebrowser
|
||||
#show-read-feeds no
|
||||
auto-reload yes
|
||||
|
||||
external-url-viewer "urlscan -dc -r 'linkhandler {}'"
|
||||
|
||||
bind-key j down
|
||||
bind-key k up
|
||||
bind-key j next articlelist
|
||||
bind-key k prev articlelist
|
||||
bind-key J next-feed articlelist
|
||||
bind-key K prev-feed articlelist
|
||||
bind-key G end
|
||||
bind-key g home
|
||||
bind-key d pagedown
|
||||
bind-key u pageup
|
||||
bind-key l open
|
||||
bind-key h quit
|
||||
bind-key a toggle-article-read
|
||||
bind-key n next-unread
|
||||
bind-key N prev-unread
|
||||
bind-key D pb-download
|
||||
bind-key U show-urls
|
||||
bind-key x pb-delete
|
||||
|
||||
color listnormal cyan default
|
||||
color listfocus black yellow standout bold
|
||||
color listnormal_unread blue default
|
||||
color listfocus_unread yellow default bold
|
||||
color info red black bold
|
||||
color article cyan default
|
||||
|
||||
browser linkhandler
|
||||
macro , open-in-browser
|
||||
macro t set browser "tsp youtube-dl --add-metadata -ic"; open-in-browser ; set browser linkhandler
|
||||
macro a set browser "tsp youtube-dl --add-metadata -xic -f bestaudio/best"; open-in-browser ; set browser linkhandler
|
||||
macro v set browser "setsid nohup mpv"; open-in-browser ; set browser linkhandler
|
||||
macro w set browser "w3m"; open-in-browser ; set browser linkhandler
|
||||
macro p set browser "dmenuhandler"; open-in-browser ; set browser linkhandler
|
||||
macro c set browser "xsel -b <<<" ; open-in-browser ; set browser linkhandler
|
||||
1757
quicklisp.lisp
1757
quicklisp.lisp
File diff suppressed because it is too large
Load diff
5
vim/.vim/.netrwhist
Normal file
5
vim/.vim/.netrwhist
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
let g:netrw_dirhistmax =10
|
||||
let g:netrw_dirhistcnt =3
|
||||
let g:netrw_dirhist_3='/home/green/.config/sxhkd'
|
||||
let g:netrw_dirhist_2='/home/green/.newsboat'
|
||||
let g:netrw_dirhist_1='/home/green/.config/sxhkd'
|
||||
18
vim/.vimrc
18
vim/.vimrc
|
|
@ -31,6 +31,9 @@
|
|||
Plug 'justinmk/vim-sneak'
|
||||
Plug 'christoomey/vim-tmux-navigator'
|
||||
Plug 'ap/vim-css-color'
|
||||
Plug 'dylanaraps/wal.vim'
|
||||
Plug 'sjl/tslime.vim'
|
||||
|
||||
" Todo:
|
||||
" GV
|
||||
" Gundo (or undotree?)
|
||||
|
|
@ -51,7 +54,9 @@
|
|||
"}}}
|
||||
|
||||
" appearance {{{
|
||||
colorscheme zenburn
|
||||
|
||||
" colorscheme zenburn
|
||||
" colorscheme wal
|
||||
syntax on " Enable syntax
|
||||
set encoding=utf-8 " Keep utf-8 encoding
|
||||
set scrolloff=2 " Keep at least 3 lines above and below cursor
|
||||
|
|
@ -207,7 +212,7 @@
|
|||
"}}}
|
||||
|
||||
" launch love game, check youtube love2d roguelike+rpg day 1 if broken {{{
|
||||
map ,t :! /Applications/love.app/Contents/MacOS/love . <CR>
|
||||
" map ,t :! /Applications/love.app/Contents/MacOS/love . <CR>
|
||||
|
||||
"}}}
|
||||
|
||||
|
|
@ -292,6 +297,15 @@
|
|||
|
||||
"}}}
|
||||
|
||||
" tmux {{{
|
||||
" tslime
|
||||
let g:tslime_ensure_trailing_newlines = 1
|
||||
let g:tslime_ensure_trailing_newlines = 1
|
||||
let g:tslime_normal_mapping = '<leader>t'
|
||||
let g:tslime_visual_mapping = '<leader>t'
|
||||
let g:tslime_vars_mapping = '<leader>T'
|
||||
|
||||
"}}}
|
||||
|
||||
" folding options, this must be last in file
|
||||
" vim:foldmethod=marker:foldlevel=0
|
||||
|
|
|
|||
300
vim/_vimrc
300
vim/_vimrc
|
|
@ -1,300 +0,0 @@
|
|||
|
||||
" vim-plug {{{
|
||||
" Automatic installation
|
||||
if empty(glob('~/.vim/autoload/plug.vim'))
|
||||
silent !curl -fLo ~/.vim/autoload/plug.vim --create-dirs
|
||||
\ https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
|
||||
autocmd VimEnter * PlugInstall --sync | source $MYVIMRC
|
||||
endif
|
||||
|
||||
call plug#begin('~/.vim/plugins')
|
||||
|
||||
Plug 'junegunn/vim-easy-align'
|
||||
Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --bin --all' }
|
||||
Plug 'tpope/vim-surround'
|
||||
Plug 'tpope/vim-commentary'
|
||||
Plug 'w0rp/ale'
|
||||
Plug 'airblade/vim-gitgutter'
|
||||
Plug 'itchyny/lightline.vim'
|
||||
Plug 'tpope/vim-repeat'
|
||||
Plug 'haya14busa/incsearch.vim'
|
||||
Plug 'gorodinskiy/vim-coloresque'
|
||||
Plug 'sheerun/vim-polyglot'
|
||||
Plug 'nvie/vim-flake8'
|
||||
Plug 'KKPMW/sacredforest-vim'
|
||||
Plug 'wolf-dog/lightline-sceaduhelm.vim'
|
||||
" Plug 'unblevable/quick-scope'
|
||||
Plug 'tpope/vim-fugitive'
|
||||
Plug 'l04m33/vlime', {'rtp': 'vim/'}
|
||||
Plug 'artanikin/vim-synthwave84'
|
||||
Plug 'kovisoft/paredit'
|
||||
Plug 'relastle/bluewery.vim'
|
||||
Plug 'sainnhe/vim-color-forest-night'
|
||||
Plug 'justinmk/vim-sneak'
|
||||
" Todo:
|
||||
" GV
|
||||
" Gundo (or undotree?)
|
||||
" Emmett
|
||||
" Fugitive
|
||||
" Vimwiki
|
||||
" Plug 'ryanss/vim-hackernews'
|
||||
" Plug 'mbbill/undotree' or Plug 'sjl/gundo.vim'
|
||||
" Plug 'tpope/vim-projectionist'
|
||||
" Plug 'mileszs/ack.vim'
|
||||
" Plug 'vim-pandoc/vim-pandoc'
|
||||
" Plug 'alfredodeza/pytest.vim'
|
||||
" Plug 'docker/docker'
|
||||
" Plug vim-scripts/indentpython.vim
|
||||
"
|
||||
call plug#end()
|
||||
|
||||
"}}}
|
||||
|
||||
" appearance {{{
|
||||
colorscheme zenburn
|
||||
syntax on " Enable syntax
|
||||
set encoding=utf-8 " Keep utf-8 encoding
|
||||
set scrolloff=2 " Keep at least 3 lines above and below cursor
|
||||
set showmode " Something something buffers
|
||||
set showcmd " Show command in bottom bar
|
||||
set wildmenu " Visual autocomplete for command menu
|
||||
set wildmode=list:longest " Show all completions on tab
|
||||
set laststatus=1 " Last window will always have statusline
|
||||
set showmatch " Highlight matching [{()}]
|
||||
set cursorline " Highlight current line
|
||||
|
||||
" remove underline on current line number
|
||||
hi CursorLineNr cterm=bold
|
||||
|
||||
" Lightline
|
||||
let g:lightline = { 'colorscheme': 'sceaduhelm', }
|
||||
set fillchars+=vert:│
|
||||
|
||||
" }}}
|
||||
|
||||
" Movement {{{
|
||||
" TODO: map alt-j and k to move text lines vertically, maintaining indent
|
||||
" }}}
|
||||
|
||||
" Folding {{{
|
||||
set foldenable " Enable folding
|
||||
set foldmethod=marker " Fold sections by marker
|
||||
set foldlevel=0 " Fold by default
|
||||
set modelines=1 " Check final line of file for modeline
|
||||
|
||||
" }}}
|
||||
|
||||
" behavior {{{
|
||||
set nocompatible " Turn off vi compatability nonsense
|
||||
set hidden " Hide buffer when opening new file
|
||||
set visualbell " Use visual bell instead of beeping
|
||||
set ttyfast " Improves smoothness and drawing
|
||||
set backspace=indent,eol,start " Always allow backspacing
|
||||
set undofile " Make .un file for persistent undo
|
||||
set relativenumber " Make numbers relative to current line
|
||||
set lazyredraw " Redraw only when necessary
|
||||
set updatetime=100 " Make updates happen faster (gitgutter)
|
||||
set splitright " Make split to right by default
|
||||
|
||||
"}}}
|
||||
|
||||
" searching {{{
|
||||
set gdefault " Remove default g flag on search
|
||||
set ignorecase " Ignore case for searches
|
||||
set smartcase " Case-specific only when uppercase
|
||||
set hlsearch " Don't continue to highlight searched phrases.
|
||||
set incsearch " But do search as characters are entered
|
||||
" Remap tab to jump by brackets
|
||||
" Nnoremap <tab> %
|
||||
" Vnoremap <tab> %
|
||||
" Remap tab to jump by window
|
||||
nnoremap <tab> <C-w>w
|
||||
vnoremap <tab> <C-w>w
|
||||
|
||||
"}}}
|
||||
|
||||
" tab settings {{{
|
||||
set tabstop=4 " Number of visual spaces per tab
|
||||
set softtabstop=4 " Should always = tabstop
|
||||
set shiftwidth=4 " Indent/outdent by 4 columns
|
||||
set expandtab " Tabs are spaces
|
||||
set shiftround " Always indent/outdent to the nearest tabstop
|
||||
" Make search terms more visible
|
||||
highlight Visual ctermbg=DarkGreen ctermfg=Black
|
||||
set autoindent " Auto indentation
|
||||
|
||||
"}}}
|
||||
|
||||
" ruler settings {{{
|
||||
set rulerformat=%l,%-2v\|%4L\ Lines " Display line, column, and total lines
|
||||
set ruler " Turn on ruler
|
||||
|
||||
"}}}
|
||||
|
||||
" long line handling {{{
|
||||
set textwidth=79
|
||||
set fo=t
|
||||
" set colorcolumn=85
|
||||
|
||||
"}}}
|
||||
|
||||
" leaders {{{
|
||||
:let mapleader = ","
|
||||
|
||||
" Clear search highlighting with leader-space
|
||||
nnoremap <leader><space> :noh<cr>
|
||||
|
||||
" Underline with line of the same length
|
||||
nnoremap <leader>- yypv$r-
|
||||
|
||||
" Insert date on current line
|
||||
nnoremap <leader>d k :r !date <cr>
|
||||
|
||||
nnoremap <leader>k :vert new ~/.vim/bindings.md <cr>
|
||||
|
||||
"}}}
|
||||
|
||||
" invisible characters {{{
|
||||
set list
|
||||
set listchars=tab:▸\ ,eol:¬
|
||||
|
||||
"}}}
|
||||
|
||||
" hjkl {{{
|
||||
" Disable arrow keys in normal and visual mode
|
||||
nnoremap <up> <nop>
|
||||
nnoremap <down> <nop>
|
||||
nnoremap <left> <nop>
|
||||
nnoremap <right> <nop>
|
||||
inoremap <up> <nop>
|
||||
inoremap <down> <nop>
|
||||
inoremap <left> <nop>
|
||||
inoremap <right> <nop>
|
||||
" Disable h and l
|
||||
" nnoremap h <nop>
|
||||
" nnoremap l <nop>
|
||||
" Make j and k move by screen line, not file line
|
||||
nnoremap j gj
|
||||
nnoremap k gk
|
||||
|
||||
"}}}
|
||||
|
||||
" split pane navigation {{{
|
||||
" Map vertical split to \ w, switch to it, open explorer, prompt for filename
|
||||
" TODO: make new window prompt use fzf
|
||||
nnoremap <leader>w <C-w>v<C-w>l:e <C-S-d><BS><BS>open
|
||||
" Switch panes wit ctrl + h/j/k/l
|
||||
nnoremap <C-h> <C-w>h
|
||||
nnoremap <C-j> <C-w>j
|
||||
nnoremap <C-k> <C-w>k
|
||||
nnoremap <C-l> <C-w>l
|
||||
nnoremap <C-c> :close <cr>
|
||||
nnoremap <C-n> :bn <cr>
|
||||
" Map resize pane
|
||||
" TODO: remap pane resize to something else (leader?)
|
||||
map + :vertical resize +5<CR>
|
||||
map - :vertical resize -5<CR>
|
||||
" quick-scope
|
||||
" Trigger a highlight in the appropriate direction when pressing these keys:
|
||||
let g:qs_highlight_on_keys = ['f', 'F', 't', 'T']
|
||||
|
||||
augroup qs_colors
|
||||
autocmd!
|
||||
autocmd ColorScheme * highlight QuickScopePrimary guifg='#afff5f' gui=underline ctermfg=155 cterm=underline
|
||||
autocmd ColorScheme * highlight QuickScopeSecondary guifg='#5fffff' gui=underline ctermfg=81 cterm=underline
|
||||
augroup END
|
||||
|
||||
"}}}
|
||||
|
||||
" launch love game, check youtube love2d roguelike+rpg day 1 if broken {{{
|
||||
map ,t :! /Applications/love.app/Contents/MacOS/love . <CR>
|
||||
|
||||
"}}}
|
||||
|
||||
" file specific {{{
|
||||
" In markdown files, when writing add two spaces to each line to fix spacing
|
||||
" In compiled version
|
||||
" au BufWritePost *.md silent! %s/[^ ]\zs$/\1 /
|
||||
" TODO: find a better solution
|
||||
" Bold something in a markdown file
|
||||
" :au FileType markdown nmap <leader>b i**<esc>ea**<esc>b
|
||||
" Python
|
||||
" au BufNewFile,BufRead *.py
|
||||
"\ set tabstop=4
|
||||
"\ set softtabstop=4
|
||||
"\ set shiftwidth=4
|
||||
"\ set textwidth=79
|
||||
"\ set expandtab
|
||||
"\ set autoindent
|
||||
"\ set fileformat=unix
|
||||
"" Webdev
|
||||
" au BufNewFile,BufRead *.js, *.html, *.css
|
||||
"\ set tabstop=2
|
||||
"\ set softtabstop=2
|
||||
"\ set shiftwidth=2
|
||||
|
||||
"}}}
|
||||
|
||||
" plugin modification {{{
|
||||
" FZF
|
||||
map <C-p> :FZF<cr>
|
||||
" This is the default extra key bindings
|
||||
let g:fzf_action = {
|
||||
\ 'ctrl-t': 'tab split',
|
||||
\ 'ctrl-x': 'split',
|
||||
\ 'ctrl-v': 'vsplit' }
|
||||
|
||||
" Default fzf layout
|
||||
" - down / up / left / right
|
||||
let g:fzf_layout = { 'down': '~30%' }
|
||||
|
||||
" Customize fzf colors to match your color scheme
|
||||
let g:fzf_colors =
|
||||
\ { 'fg': [ 'fg', 'Normal'],
|
||||
\ 'bg': [ 'bg', 'Normal'],
|
||||
\ 'hl': [ 'fg', 'Comment'],
|
||||
\ 'fg+': [ 'fg', 'CursorLine', 'CursorColumn', 'Normal'],
|
||||
\ 'bg+': [ 'bg', 'CursorLine', 'CursorColumn'],
|
||||
\ 'hl+': [ 'fg', 'Statement'],
|
||||
\ 'info': [ 'fg', 'PreProc'],
|
||||
\ 'border': [ 'fg', 'Ignore'],
|
||||
\ 'prompt': [ 'fg', 'Conditional'],
|
||||
\ 'pointer': [ 'fg', 'Exception'],
|
||||
\ 'marker': [ 'fg', 'Keyword'],
|
||||
\ 'spinner': [ 'fg', 'Label'],
|
||||
\ 'header': [ 'fg', 'Comment'] }
|
||||
|
||||
" EasyAlign
|
||||
"" Start interactive EasyAlign in visual mode (e.g. vipga)
|
||||
xmap ga <Plug>(EasyAlign)
|
||||
" Start interactive EasyAlign for a motion/text object (e.g. gaip)
|
||||
nmap ga <Plug>(EasyAlign)
|
||||
|
||||
"}}}
|
||||
|
||||
" git commands {{{
|
||||
" TODO: map fugitive commands
|
||||
" TODO: check out gv etc
|
||||
" TODO: bind hunk committing
|
||||
" Gitgutter hunk view
|
||||
nmap ghv <Plug>(GitGutterPreviewHunk)
|
||||
nmap ghn <Plug>(GitGutterNextHunk)
|
||||
nmap ghp <Plug>(GitGutterPrevHunk)
|
||||
nmap ghf <Plug>(GitGutterFold)
|
||||
|
||||
"}}}
|
||||
|
||||
" plugin modification {{{
|
||||
|
||||
"}}}
|
||||
|
||||
" gvim {{{
|
||||
set guioptions=Ace
|
||||
set guifont="Bitstream Vera Sans Mono"
|
||||
|
||||
"}}}
|
||||
|
||||
|
||||
" folding options, this must be last in file
|
||||
" vim:foldmethod=marker:foldlevel=0
|
||||
|
||||
69
zsh/.zshrc
Normal file
69
zsh/.zshrc
Normal file
|
|
@ -0,0 +1,69 @@
|
|||
autoload -U colors && colors
|
||||
PS1="%B%{$fg[red]%}[%{$fg[yellow]%}%n%{$fg[green]%}@%{$fg[blue]%}%M %{$fg[magenta]%}%~%{$fg[red]%}]%{$reset_color%}$%b "
|
||||
|
||||
# Load aliases and shortcuts if existent.
|
||||
[ -f "$HOME/.config/shortcutrc" ] && source "$HOME/.config/shortcutrc"
|
||||
[ -f "$HOME/.config/aliasrc" ] && source "$HOME/.config/aliasrc"
|
||||
|
||||
autoload -U compinit
|
||||
zstyle ':completion:*' menu select
|
||||
zmodload zsh/complist
|
||||
compinit
|
||||
|
||||
# Include hidden files in autocomplete:
|
||||
_comp_options+=(globdots)
|
||||
|
||||
# Use vim keys in tab complete menu:
|
||||
bindkey -M menuselect 'h' vi-backward-char
|
||||
bindkey -M menuselect 'k' vi-up-line-or-history
|
||||
bindkey -M menuselect 'l' vi-forward-char
|
||||
bindkey -M menuselect 'j' vi-down-line-or-history
|
||||
bindkey -v '^?' backward-delete-char
|
||||
|
||||
export KEYTIMEOUT=1
|
||||
|
||||
# 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
|
||||
|
||||
# Use beam shape cursor on startup.
|
||||
echo -ne '\e[5 q'
|
||||
# Use beam shape cursor for each new prompt.
|
||||
preexec() { echo -ne '\e[5 q' ;}
|
||||
|
||||
# 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"
|
||||
if [ -d "$dir" ]; then
|
||||
if [ "$dir" != "$(pwd)" ]; then
|
||||
cd "$dir"
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
bindkey -s '^o' 'lfcd\n' # zsh
|
||||
|
||||
# Load zsh-syntax-highlighting; should be last.
|
||||
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh 2>/dev/null
|
||||
Loading…
Add table
Add a link
Reference in a new issue