Skip to content

Instantly share code, notes, and snippets.

View jbenner-radham's full-sized avatar

James Benner jbenner-radham

View GitHub Profile
@jbenner-radham
jbenner-radham / update-git-author-info.sh
Created October 22, 2019 13:04
Update Git author info.
#!/usr/bin/env sh
# From: https://help.github.com/en/github/using-git/changing-author-info
git filter-branch --env-filter '
OLD_EMAIL="[email protected]"
CORRECT_NAME="James Benner"
CORRECT_EMAIL="[email protected]"
#!/usr/bin/env sh
say --voice=Kyoko --rate=0 --interactive=bold rei ichi ni san yon go roku nana hachi kyuu juu juuichi juuni juusan juushi juugo juuroku juushichi juuhachi juuku nijuu nijuuichi nijuuni nijuusan nijuushi nijuugo nijuuroku nijuushichi nijuuhachi nijuuku sanjuu sanjuuichi sanjuuni sanjuusan sanjuushi sanjuugo sanjuuroku sanjuushichi sanjuuhachi sanjuuku yonjuu yonjuuichi yonjuuni yonjuusan yonjuushi yonjuugo yonjuuroku yonjuushichi yonjuuhachi yonjuuku gojuu gojuuichi gojuuni gojuusan gojuushi gojuugo gojuuroku gojuushichi gojuuhachi gojuuku rokujuu rokujuuichi rokujuuni rokujuusan rokujuushi rokujuugo rokujuuroku rokujuushichi rokujuuhachi rokujuuku nanajuu nanajuuichi nanajuuni nanajuusan nanajuushi nanajuugo nanajuuroku nanajuushichi nanajuuhachi nanajuuku hachijuu hachijuuichi hachijuuni hachijuusan hachijuushi hachijuugo hachijuuroku hachijuushichi hachijuuhachi hachijuuku kyuujuu kyuujuuichi kyuujuuni kyuujuusan kyuujuushi kyuujuugo kyuujuuroku kyuujuushichi kyuujuuhachi kyuujuuku hyakus
@jbenner-radham
jbenner-radham / lsdir.sh
Created September 4, 2019 21:26
Shell script to list only directories.
#!/usr/bin/env sh
lsdir () {
if [ "${1}" ]; then file=$1; else file='.'; fi
# shellcheck disable=SC2010
ls -Al "${file}" | grep '^d' | awk '{print $NF}'
}
Array.from(document.head.querySelectorAll('meta'))
.filter(tag => tag.name && tag.content)
.forEach(tag => console.log(`${tag.name}: ${tag.content}`));
@jbenner-radham
jbenner-radham / scratch.scss
Last active February 15, 2019 15:27
SCSS scratch file.
@function make-long-shadow($color, $recursions: 200) {
$shadows: 0 0 $color;
@for $i from 1 through $recursions {
$shadows: $shadows, #{$i}px #{$i}px #{$color};
}
@return $shadows;
}
@jbenner-radham
jbenner-radham / long-shadow.scss
Created February 14, 2019 02:08
Playing with long shadows in SCSS.
@function long-shadow($color, $recursions: 200) {
$shadows: 0 0 $color;
@for $i from 1 through $recursions {
$shadows: $shadows, #{$i}px #{$i}px #{$color};
}
@return $shadows;
}
@jbenner-radham
jbenner-radham / .eslintrc.js
Created February 12, 2019 18:35
ESLint config boilerplate.
/**
* @see https://eslint.org/docs/rules/
*/
module.exports = {
extends: 'eslint:recommended',
root: true,
rules: {
'arrow-spacing': 'error',
'block-spacing': 'error',
camelcase: 'error',