People who released notable new records I haven't listened to enough of to have a strong opinion on:
- Low
- Cloud Nothings
- Cursive
- Foxing “Nearer my god”
- Mewithoutyou
- Interpol
VPATH=/usr/local/bin | |
BINARIES=ruby node | |
all : ${BINARIES} | |
echo "Deps are installed" | |
${BINARIES} : | |
asdf plugin-add $@ |
# asdf --------------------------------------------------------------------- {{{ | |
# TODO: This is horrible. Do this in a loop and stash the results of `asdf | |
# plugin-list` so you only have to call it once. | |
node_installed := $(shell [[ "$(shell asdf plugin-list)" == *nodejs* ]] && echo 0 || echo 1) | |
ruby_installed := $(shell [[ "$(shell asdf plugin-list)" == *ruby* ]] && echo 0 || echo 1) | |
golang_installed := $(shell [[ "$(shell asdf plugin-list)" == *golang* ]] && echo 0 || echo 1) | |
rust_installed := $(shell [[ "$(shell asdf plugin-list)" == *rust* ]] && echo 0 || echo 1) | |
python_installed := $(shell [[ "$(shell asdf plugin-list)" == *python* ]] && echo 0 || echo 1) |
" Auto-Completion --------------------------------------------------------- {{{ | |
" Use TAB to complete when typing words, else inserts TABs as usual. | |
function! Tab_Or_Complete(move_to_next_word) abort | |
" If auto-complete menu is not open and we are in the middle of typing a | |
" word OR if auto-complete menu is already open the `tab` cycles through | |
" suggested completions. | |
if pumvisible() || (col('.')>1 && strpart( getline('.'), col('.')-2, 3 ) =~ '^\w') | |
return a:move_to_next_word | |
else |
" Uses Dispatch to print the flow type of the variable under the cursor. | |
" | |
" Example: | |
" | |
" ```javascript | |
" | |
" type Person = {age: number, name: string, sex: 'male' | 'female'} | |
" const person: Person = {age: 35, name: 'Bob', sex: 'male'}; | |
" const {a|ge, sex} = person; | |
" ^ |
A * means it’s on the more intense and disturbing end of the spectrum. And if you think I missed a great one feel free to tweet at me at @jsatk.
const config = Object.freeze({ | |
async: true, | |
page: 4 | |
}); | |
const getThing = config => { | |
const awesomeFunction = options => { | |
const updatedOptions = Object.assign({}, options, { | |
offset: options.offset || 10 | |
}); |
const options = Object.freeze({ | |
async: true, | |
page: 4 | |
}); | |
const awesomeFunction = options => { | |
const updatedOptions = Object.assign({}, options, { | |
offset: options.offset || 10 | |
}); | |
const options = { | |
async: true, | |
page: 4 | |
}; | |
const awesomeFunction = options => { | |
if (!options.offset) { | |
options.offset = 10; | |
} | |
const rectangle = (height, width) => ({ | |
height, | |
width, | |
get area() { | |
return height * width; | |
} | |
}); | |
const myRectangle = rectangle(10, 20); | |
myRectangle.area // => 200 |