I hereby claim:
- I am mathewdgardner on github.
- I am mathewdgardner (https://keybase.io/mathewdgardner) on keybase.
- I have a public key ASBd0XZPBbZT8T2lSIrSp_0kafmtp5rKgaE8whWxO1qADgo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
defmodule Sample do | |
@moduledoc """ | |
Sample showcasing the power of Elixir recursion and flattening lists of arbitrary depth. | |
""" | |
@doc """ | |
Flatten lists with arbitrary depths. | |
## Examples |
#!/bin/bash -e | |
# $0 - Required module name | |
# $1 - Optional minimum version | |
module=$1 | |
# Assert we have a module to install | |
: ${module:?} |
#!/bin/bash | |
# Save docker images | |
ds() { | |
docker images | \ | |
cut -d ' ' -f 1 | \ | |
tail -n +2 | \ | |
xargs -t -n 1 -I {} -P 4 \ | |
sh -c 'docker save {} | bzip2 > $(echo "{}" | sed "s/^.*\///").tar.bz2' | |
} |
#!/bin/bash | |
# Recursively go up ancestor directories looking for a docker-compose.yml file | |
function check() { | |
if [ -f "$1/docker-compose.yml" ]; then | |
compose_file="$1/docker-compose.yml" | |
echo "Using $compose_file for friendly names..." | |
elif [ "$1" = "/" ]; then | |
echo "Error: No docker-compose.yml file found" && exit 1 | |
elif [ -d "$1" ]; then |