diff options
| author | Mehdi Sadeghi <mehdi@mehdix.org> | 2022-02-21 10:20:00 +0100 |
|---|---|---|
| committer | Mehdi Sadeghi <mehdi@mehdix.org> | 2022-03-12 13:50:56 +0100 |
| commit | 61a1a18ec6616491a5472b6f94226c8126cf764a (patch) | |
| tree | 54fbf80beefb54181ea73c59fa0c59de0f5560eb | |
| parent | a2a18f7095eb78b6293a7d549e32da91005f65d7 (diff) | |
Add mutt/rock stuff.
| -rw-r--r-- | .bashrc | 15 | ||||
| -rw-r--r-- | .config/i3status/config | 4 | ||||
| -rw-r--r-- | .config/isync/mbsyncrc | 21 | ||||
| -rw-r--r-- | .config/mutt/muttrc | 22 | ||||
| -rw-r--r-- | .config/sway/config | 10 | ||||
| -rw-r--r-- | .config/systemd/user/mbsync.service | 9 | ||||
| -rw-r--r-- | .config/systemd/user/mbsync.timer | 10 | ||||
| -rw-r--r-- | .env | 4 | ||||
| -rw-r--r-- | .profile | 5 | ||||
| -rw-r--r-- | .vimrc | 72 |
10 files changed, 96 insertions, 76 deletions
@@ -1,3 +1,4 @@ +echo .bashrc begin # .bashrc [ $0 != sh ] && [ -n "${ENV:=$HOME/.env}" ] && . "$ENV" @@ -27,16 +28,4 @@ complete -D -F _completion_loader -o bashdefault -o default [ -f ~/.config/broot/launcher/bash/br ] && . ~/.config/broot/launcher/bash/br [ -f ~/.local/src/z.sh ] && . ~/.local/src/z.sh -# direnv hook -_direnv_hook() { - local previous_exit_status=$?; - trap -- '' SIGINT; - eval "$("/usr/bin/direnv" export bash)"; - trap - SIGINT; - return $previous_exit_status; -}; - -if ! [[ "${PROMPT_COMMAND:-}" =~ _direnv_hook ]]; then - PROMPT_COMMAND="_direnv_hook${PROMPT_COMMAND:+;$PROMPT_COMMAND}" -fi - +echo .bashrc end diff --git a/.config/i3status/config b/.config/i3status/config index d064a7c..b5f64fb 100644 --- a/.config/i3status/config +++ b/.config/i3status/config @@ -39,8 +39,8 @@ ethernet _first_ { battery 0 { format = "%status %percentage %remaining %emptytime" #path = "/sys/class/power_supply/rk-bat/uevent" - #path = "/sys/class/power_supply/cw2015-battery/uevent" - path = "/sys/class/power_supply/BAT0/uevent" + path = "/sys/class/power_supply/cw2015-battery/uevent" + #path = "/sys/class/power_supply/BAT0/uevent" } tztime local { diff --git a/.config/isync/mbsyncrc b/.config/isync/mbsyncrc new file mode 100644 index 0000000..f138920 --- /dev/null +++ b/.config/isync/mbsyncrc @@ -0,0 +1,21 @@ +IMAPAccount main +Host mail.mehdix.org +User mehdi@mehdix.org +PassCmd "pass mail/mx" +SSLType IMAPS +AuthMechs LOGIN + +IMAPStore main-remote +Account main + +MaildirStore main-local +Subfolders Verbatim +Path ~/Maildir/main/ +Inbox ~/Maildir/main/Inbox + +Channel main +Far :main-remote: +Near :main-local: +Patterns * +Create Both +SyncState * diff --git a/.config/mutt/muttrc b/.config/mutt/muttrc index 741cdd4..92c650b 100644 --- a/.config/mutt/muttrc +++ b/.config/mutt/muttrc @@ -1,8 +1,26 @@ +# Main config for Maildir (by mbsync) +set folder = "~/Maildir/main" +set mbox_type = Maildir +set spoolfile = +Inbox +set record = +Sent +set postponed = +Drafts +set header_cache = ~/.cache/mutt + +# Some nice to have +set sort = threads +set sort_aux = reverse-last-date-received +set date_format = "%y/%m/%d %I:%M%p" + +# HTML +set mailcap_path = "~/.config/mutt/mailcap" +auto_view text/html +alternative_order text/plain text/enriched text/html + # Read imap_pass source ~/.config/mutt/secret # IMAP -set spoolfile = imaps://mail.mehdix.org/ +#set spoolfile = imaps://mail.mehdix.org/ set imap_user = mehdi@mehdix.org # SMTP @@ -16,4 +34,4 @@ set smtp_url = smtp://$imap_user@mehdix.org:587/ lists sr.ht-discuss set reply_to = "ask-yes" -source ~/.config/mutt/`hostname` +#source ~/.config/mutt/`hostname` diff --git a/.config/sway/config b/.config/sway/config index bb9c126..2e4eb3d 100644 --- a/.config/sway/config +++ b/.config/sway/config @@ -4,7 +4,7 @@ set $down j set $up k set $right l set $mod Mod4 -set $term foot +set $term foot-extra # Note: pass the final command to swaymsg so that the resulting window can be opened # on the original workspace that the command was run on. @@ -25,10 +25,10 @@ output * bg /usr/share/backgrounds/sway/Sway_Wallpaper_Blue_1920x1080.png fill # # Example configuration: # -exec swayidle -w \ - timeout 300 'swaylock -f -c 000000' \ - timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \ - before-sleep 'swaylock -f -c 000000' +#exec swayidle -w \ +# timeout 300 'swaylock -f -c 000000' \ +# timeout 600 'swaymsg "output * dpms off"' resume 'swaymsg "output * dpms on"' \ +# before-sleep 'swaylock -f -c 000000' # This will lock your screen after 300 seconds of inactivity, then turn off # your displays after another 300 seconds, and turn your screens back on when diff --git a/.config/systemd/user/mbsync.service b/.config/systemd/user/mbsync.service new file mode 100644 index 0000000..cebd702 --- /dev/null +++ b/.config/systemd/user/mbsync.service @@ -0,0 +1,9 @@ +[Unit] +Description=Mailbox synchronization service + +[Service] +Type=oneshot +ExecStart=/usr/bin/mbsync -ac ${HOME}/.config/isync/mbsyncrc + +[Install] +WantedBy=default.target diff --git a/.config/systemd/user/mbsync.timer b/.config/systemd/user/mbsync.timer new file mode 100644 index 0000000..82ebb83 --- /dev/null +++ b/.config/systemd/user/mbsync.timer @@ -0,0 +1,10 @@ +[Unit] +Description=Mailbox synchronization timer + +[Timer] +OnBootSec=2m +OnUnitActiveSec=5m +Unit=mbsync.service + +[Install] +WantedBy=timers.target @@ -1,3 +1,4 @@ +echo .env begin # .env PS1='$(prompt)' @@ -30,6 +31,7 @@ alias gl='git pull' alias gcm='git checkout master' alias gco='git checkout' alias gst='git status' +alias mbsync="mbsync -c ~/.config/isync/mbsyncrc" # Use correct TTY for GPG Pinentry export GPG_TTY="$(tty)" @@ -41,3 +43,5 @@ export PATH=$HOME/.cargo/bin:$PATH export GOPATH="$HOME/.local/share/go" export PATH=$GOPATH/bin:$PATH +export BROWSER=w3m +echo .env end @@ -1,9 +1,10 @@ +echo .profile begin # .profile export ENV=~/.env export LANG=en_US.UTF-8 export LC_TIME=de_DE.UTF-8 export EDITOR=vim -export TERM=foot-extra +#export TERM=foot-extra export HISTSIZE=65535 export MAKEFLAGS=-j`lscpu | grep '^CPU(s):' | awk -F' ' '{ print $2 }'` @@ -15,3 +16,5 @@ export GDK_BACKEND=wayland [ -e .config/$(hostname).profile ] && . .config/$(hostname).profile [ $0 != sh ] && [ -n $BASH_VERSION ] && shopt login_shell 2>&1 > /dev/null && [ -f ~/.bashrc ] && . ~/.bashrc + +echo .profile end @@ -1,62 +1,28 @@ -set nocompatible " required -set tabstop=4 -filetype off " required - -" set the runtime path to include Vundle and initialize -set rtp+=~/.vim/bundle/Vundle.vim -call vundle#begin() - -" alternatively, pass a path where Vundle should install plugins -"call vundle#begin('~/some/path/here') - -" let Vundle manage Vundle, required -Plugin 'gmarik/Vundle.vim' - -" add all your plugins here (note older versions of Vundle -" used Bundle instead of Plugin) - -Plugin 'vim-syntastic/syntastic' -Plugin 'vim-airline/vim-airline' -Plugin 'vim-airline/vim-airline-themes' -Plugin 'nvie/vim-flake8' -Plugin 'scrooloose/nerdtree' -Plugin 'kien/ctrlp.vim' -Plugin 'rust-lang/rust.vim' -Plugin 'racer-rust/vim-racer' -Plugin 'ConradIrwin/vim-bracketed-paste' -"Bundle 'Valloric/YouCompleteMe' -Plugin 'junegunn/fzf' -" Save the buffer whenever text is changed. -" https://stackoverflow.com/a/55761306 -" autocmd TextChanged,TextChangedI <buffer> silent write - - -" All of your Plugins must be added before the following line -call vundle#end() " required -filetype plugin indent on " required - -let python_highlight_all=1 -let g:airline_theme='wombat' -set encoding=utf-8 -set mouse-=a +set rtp+=/usr/bin/fzf syntax on -"split navigations +" Pane navigation nnoremap <C-J> <C-W><C-J> nnoremap <C-K> <C-W><C-K> nnoremap <C-L> <C-W><C-L> nnoremap <C-H> <C-W><C-H> -au BufNewFile,BufRead *.py - \ set tabstop=4 | - \ set softtabstop=4 | - \ set shiftwidth=4 | - \ set textwidth=79 | - \ set expandtab | - \ set autoindent | - \ set fileformat=unix +" Use ctrl-[hjkl] to select the active split! +"nmap <silent> <c-k> :wincmd k<CR> +"nmap <silent> <c-j> :wincmd j<CR> +"nmap <silent> <c-h> :wincmd h<CR> +"nmap <silent> <c-l> :wincmd l<CR> + +" Source vimrc in $CWD in a secure way +set exrc +set secure + + +:source /home/rock/.vim/right_align.vim -"au BufRead,BufNewFile *.py,*.pyw,*.c,*.h match BadWhitespace /\s\+$/ -let NERDTreeIgnore=['\.pyc$', '\~$'] "ignore files in NERDTree -map <C-n> :NERDTreeToggle<CR> +set arabicshape! +let g:RightAlign_RightBorder = 80 +imap <silent> <C-b> <Plug>RightAlign +nmap <silent> <C-k>b :RightAlign<CR> +vmap <silent> <C-k>b :RightAlign<CR> |
