Last active
August 19, 2021 06:46
-
-
Save luke-rmaki/ae69ce60a2245c03afb7e26351ceba5d to your computer and use it in GitHub Desktop.
Dot Files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| " -------------------------------------------------------BASIC SETUP | |
| set nocompatible " be iMproved, required | |
| filetype off " required | |
| syntax on | |
| "--------------------------------------------------------VUNDLE | |
| " set the runtime path to include Vundle and initialize | |
| set rtp+=~/.vim/bundle/Vundle.vim | |
| call vundle#begin() | |
| "---------------------------------------------------------PLUGINS | |
| " let Vundle manage Vundle, required | |
| Plugin 'VundleVim/Vundle.vim' | |
| " Surround | |
| Plugin 'tpope/vim-surround' | |
| " NERD Tree | |
| Plugin 'scrooloose/nerdtree' | |
| " Emmet | |
| Plugin 'mattn/emmet-vim' | |
| " Indent guides | |
| Plugin 'nathanaelkane/vim-indent-guides' | |
| " All of your Plugins must be added before the following line | |
| call vundle#end() | |
| filetype plugin indent on | |
| "---------------------------------------------------------EDITOR SETTINGS | |
| set autoindent | |
| set ruler | |
| set visualbell | |
| set nu rnu "set relative numbers | |
| set tabstop=2 | |
| set softtabstop=2 | |
| set showcmd | |
| set showmatch "show matching bracket | |
| filetype indent on | |
| "---------------------------------------------------------PLUGIN SETTINGS | |
| "NERD Tree | |
| "autocmd vimenter * NERDTree "auto open on editor start | |
| map <C-o> :NERDTreeToggle<CR> | |
| autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif "close vim if only window open is nerd tree | |
| " Emmet | |
| imap <expr> <tab> emmet#expandAbbrIntelligent("\<tab>") "set trigger to tab |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Path to your oh-my-zsh installation. | |
| export ZSH="/home/luke/.oh-my-zsh" | |
| ZSH_THEME="amuse" | |
| plugins=(git) | |
| source $ZSH/oh-my-zsh.sh | |
| # Preferred editor for local and remote sessions | |
| if [[ -n $SSH_CONNECTION ]]; then | |
| export EDITOR='vim' | |
| else | |
| export EDITOR='mvim' | |
| fi | |
| # Welcome message | |
| echo "Welcome Luke ==>" | |
| # Aliases | |
| alias config='vim ~/.zshrc' | |
| alias src='source ~/.zshrc' | |
| alias cls='clear' | |
| alias pj='cd /mnt/c/Users/lukes/Projects' | |
| alias lukes='cd /mnt/c/Users/lukes' | |
| alias code="code" | |
| alias cra="npm init react-app" | |
| alias ls="ls -thor" | |
| alias deploy="git push origin master && netlify watch" | |
| alias vimconfig="vim ~/.vimrc" | |
| alias chrome='/mnt/c/Program\ Files\ \(x86\)/Google/Chrome/Application/chrome.exe --remote-debugging-port=9222' | |
| alias server='ssh [email protected]' | |
| #powershell | |
| alias ntop='ps ntop' | |
| alias ps='powershell.exe' | |
| alias open="explorer.exe ." | |
| alias edge="ps start microsoft-edge:" | |
| alias github="ps start 'https://github.com/luke-rmaki'" | |
| # Ledger | |
| alias ledger-balance='ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md balance' | |
| alias ledger-bank='ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md balance Bank' | |
| # Functions | |
| function chpwd() { | |
| emulate -L zsh | |
| ls -a -thor | |
| } | |
| function reload() { | |
| echo "Reloading...." | |
| source ~/.zshrc | |
| } | |
| function commit() { | |
| if [[ "$1" != "" ]] | |
| then | |
| git add . | |
| git commit -m "$1" | |
| else | |
| echo "Please enter a message" | |
| fi | |
| } | |
| function merge() { | |
| if [[ "$1" != "" ]] | |
| then | |
| git checkout master | |
| git merge $1 | |
| git checkout $1 | |
| else | |
| echo "Please enter a branch to merge" | |
| fi | |
| } | |
| function push() { | |
| git checkout master | |
| git push origin master | |
| git checkout develop | |
| } | |
| function ledger-assets() { | |
| if [ -z "$1" ] | |
| then | |
| ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md balance Assets | |
| else | |
| ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md balance "$1" | |
| fi | |
| } | |
| function ledger-expenses() { | |
| if [ -z "$1" ] | |
| then | |
| ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md balance Expenses | |
| else | |
| ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md balance "$1" | |
| fi | |
| } | |
| function ledger-transactions() { | |
| if [ -z "$1" ] | |
| then | |
| ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md register | |
| else | |
| ledger -f ~/lukes/Documents/Notes/Rmaki/Finance/2022\ -\ Finance/Ledger.md register "$1" | |
| fi | |
| } | |
| zeal-docs-fix() { | |
| pushd "$HOME/.local/share/Zeal/Zeal/docsets" >/dev/null || return | |
| find . -iname 'react-main*.js' -exec rm '{}' \; | |
| popd >/dev/null || exit | |
| } | |
| # NVM | |
| export NVM_DIR="$HOME/.nvm" | |
| [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm | |
| [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion | |
| # X-server | |
| export DISPLAY=$(cat /etc/resolv.conf | grep nameserver | awk '{print $2; exit;}'):0.0 | |
| sudo /etc/init.d/dbus start &> /dev/null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # espanso configuration file | |
| # This is the default configuration file, change it as you like it | |
| # You can refer to the official documentation: | |
| # https://espanso.org/docs/ | |
| show_icon: false | |
| # Matches are the substitution rules, when you type the "trigger" string | |
| # it gets replaced by the "replace" string. | |
| matches: | |
| # Simple text replacement | |
| - trigger: ":espanso" | |
| replace: "Hi there!" | |
| # Dates | |
| - trigger: ":date" | |
| replace: "{{mydate}}" | |
| vars: | |
| - name: mydate | |
| type: date | |
| params: | |
| format: "%m/%d/%Y" | |
| # Emojis | |
| - trigger: ":smile" | |
| replace: "π" | |
| - trigger: ":laugh" | |
| replace: "π" | |
| - trigger: ":sad" | |
| replace: "π" | |
| - trigger: ":cry" | |
| replace: "π’" | |
| - trigger: ":thumb" | |
| replace: "π" | |
| - trigger: ":poo" | |
| replace: "π©" | |
| #Territory stuff | |
| - trigger: ":mapout" | |
| form: > | |
| Hey {{name}}, | |
| I've assigned map {{number}} to you. | |
| Kind regards, | |
| Luke | |
| - trigger: ":maps" | |
| form: > | |
| Hey {{name}}, | |
| Thanks for the update. | |
| I've assigned map {{number}} to you. | |
| Kind regards, | |
| Luke | |
| - trigger: ":mapin" | |
| form: > | |
| Hey {{name}}, | |
| Thanks for the update. | |
| Kind regards, | |
| Luke | |
| - trigger: ":mapemail" | |
| replace: > | |
| Hi all, | |
| Please see below or the attached spreadsheet for a list of maps currently assigned to you. | |
| # Misc | |
| - trigger: ":thanks" | |
| replace: "Thanks for letting me know" | |
| - trigger: ":sig" | |
| replace: > | |
| Kind regards, | |
| Luke | |
| # Theocratic | |
| - trigger: ":jeh" | |
| replace: "Jehovah" | |
| - trigger: ":jw" | |
| replace: "Jehovah's Witnesses" | |
| - trigger: ":brsis" | |
| replace: "brothers and sisters" | |
| - trigger: ":hs" | |
| replace: "Holy Spirit" | |
| - trigger: ":front" | |
| replace: | | |
| --- | |
| tags: $|$ | |
| --- | |
| - trigger: ":today" | |
| replace: "{{output}}" | |
| vars: | |
| - name: output | |
| type: shell | |
| params: | |
| cmd: echo `date +%d-%m-%Y` | |
| shell: wsl | |
| - trigger: ":bc" | |
| replace: "{{output}}" | |
| vars: | |
| - name: output | |
| type: shell | |
| params: | |
| cmd: (echo "[[$((Get-Date).AddDays(-1) | Get-Date -UFormat "%d-%m-%Y")|<< Yesterday]] | [[$((Get-Date).AddDays(+1) | Get-Date -UFormat "%d-%m-%Y")|Tomorrow >>]]") | |
| - trigger: ":log" | |
| replace: "{{output}}" | |
| vars: | |
| - name: output | |
| type: shell | |
| params: | |
| cmd: echo `date +%R` "=> " | |
| shell: wsl | |
| - trigger: ":tfu" | |
| replace: "Thanks for the update. " | |
| - trigger: ":babe" | |
| replace: "Hey babe, how was your morning?" | |
| - trigger: ":ledger" | |
| form: > | |
| {{yyyy}}/{{mm}}/{{dd}} {{payee}} | |
| {{account1}} ${{credit}} | |
| {{account2}} $-{{debit}} | |
| - trigger: ":housecar" | |
| form: > | |
| 2021/{{mm}}/{{dd}} {{payee}} | |
| Assets:Savings:House&Car ${{amount}} | |
| Assets:Checking:Bills&Rent $-{{amount}} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment