Based on the things I actually care about.
| Rule | Airbnb | Standard |
|---|---|---|
| Semicolons | Required | Never |
| Trailing Comma | Required | Never |
| Re-assign function param | Never | Allowed |
++ |
Never | Allowed |
| set -e | |
| DOMAIN=example.com | |
| [email protected] | |
| WORKADVENTURE_START_ROOM='_\/global\/workadventure.github.io\/game-room\/map.json' | |
| JITSI_TIMEZONE='UTC' | |
| JITSI_CONFIG_DIR="\/etc\/jitsi" | |
| function setEnv() { | |
| sed -i "s/#\?${1}=.*/${1}=${2}/" ${3} |
| #!/bin/bash | |
| read -p "Are you sure? " sure | |
| while [[ "${sure}" != "yes" && "${sure}" != "no" ]]; do | |
| read -p "Please type 'yes' or 'no' " sure | |
| done | |
| echo "${sure}" |
| #------------- min (0 - 59) | |
| # +----------- hour (0 - 23) | |
| # | +--------- day of month (1 - 31) | |
| # | | +------- month (1 - 12) | |
| # | | | +----- day of week (0 - 6) (Sunday=0) | |
| # | | | | | |
| # * * * * command to be executed |
| #!/usr/bin/env groovy | |
| void usage(){ | |
| println """ | |
| usage: ${this.class.name}.groovy [-p, -g] [n] | |
| Generates technobabble. | |
| -p Print n paragraphs instead of n phrases. An optional third | |
| argument may be used to specify the number of sentences per |
| #!/bin/bash | |
| # Exit with non-zero (i.e. reject the commit) if anything fails, particularly | |
| # the gradle tasks. | |
| set -e | |
| # change to the project root directory | |
| cd $(git rev-parse --show-toplevel) | |
| if [[ "$(git rev-parse --abbrev-ref HEAD)" == "dev" ]]; then |
| #!/bin/bash | |
| temp_dir="/tmp" | |
| if [ -d "${TEMP}" ]; then | |
| temp_dir="${TEMP}" | |
| fi | |
| this_file="$(basename ${0})" | |
| temp_file="${temp_dir}/${this_file%.*}.$$.$RANDOM" | |
| function cleanup { |
I hereby claim:
To claim this, I am signing this object:
frame horizontal up --> :topleft split
frame horizontal down --> :botright split
frame vertical left --> :topleft vsplit
frame vertical right --> :botright vsplit
window horizontal up --> :leftabove split
window horizontal down --> :rightbelow split
window vertical left --> :leftabove vsplit
window vertical right --> :rightbelow vsplit
| #!/bin/bash | |
| echo "\${0} = ${0}" | |
| echo "dirname \${0} = `dirname ${0}`" | |
| echo "basename \${0} = `basename ${0}`" | |
| echo "readlink -m \${0} = `readlink -m ${0}`" #In BSD (maybe not with -m option, though) | |
| echo "realpath -m \${0} = `realpath -m ${0}`" #Easy to remember | |
| echo "\$(cd \$(dirname \${0}); pwd)/\$(basename ${0}) = $(cd $(dirname ${0}); pwd)/$(basename ${0})" #Should be truly cross-platform | |
| echo "\${0/%.sh/.foo} = ${0/%.sh/.foo}" |