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
unbind r | |
bind r source-file ~/.tmux.conf | |
set -g mouse on | |
# set-option -g default-shell /opt/homebrew/bin/zsh | |
unbind C-b | |
set-option -g prefix M-z |
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
let mapleader="," | |
source ~/.cocrc | |
call plug#begin() | |
" Autocompletion | |
Plug 'neoclide/coc.nvim', { 'branch': 'release' } | |
Plug 'Shougo/vimproc.vim', {'do' : 'make'} " Interactive command execution in Vim. | |
" Source Control | |
Plug 'airblade/vim-gitgutter' |
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
inoremap <expr> <CR> pumvisible() ? "\<C-Y>" : "\<CR>" | |
function! CheckBackSpace() abort | |
let col = col('.') - 1 | |
return !col || getline('.')[col - 1] =~ '\s' | |
endfunction | |
" Insert <tab> when previous text is space, refresh completion if not. | |
inoremap <silent><expr> <TAB> | |
\ coc#pum#visible() ? coc#pum#next(1): |
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
const LIMIT = 10000; | |
const isLessOrEqualToZero = (amount) => amount <= 0; | |
const isMoreThanLimit = (amount) => amount > LIMIT; | |
const isAmountValid = (ctx) => !ctx.error; | |
const addCash = assign((ctx, event) =>({ | |
amount: event.payload.amount |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
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
//////////////////////////////////////////////// | |
// HELPERS | |
//////////////////////////////////////////////// | |
const todaysDate = new Date(); | |
const zeroPad = (num, places) => String(num).padStart(places, '0'); | |
const calculateDateAfterYears = (d, years) => { | |
return new Date(`${zeroPad(d.getDate(), 2)}-${zeroPad(d.getMonth(), 2)}-${d.getFullYear() + years}`); |
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
//////////////////////////////////////////////// | |
// HELPERS | |
//////////////////////////////////////////////// | |
const todaysDate = new Date(); | |
const zeroPad = (num, places) => String(num).padStart(places, '0'); | |
const getDateInYears = (years, d) => { |
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
// Available variables: | |
// - Machine | |
// - interpret | |
// - assign | |
// - send | |
// - sendParent | |
// - spawn | |
// - raise | |
// - actions |
NewerOlder