Fish:
$ set -x GPG_TTY (tty)
Bash:
#!/usr/bin/env bash | |
set -euo pipefail | |
# save current versions of zig and zls for summary output | |
zig_before=$(zig version) | |
zls_before=$(zls --version) | |
archive_url="https://zigbin.io/master/aarch64-macos.tar.xz" | |
archive="zig-macos-aarch64.tar.xz" | |
zig_dir="${archive%%.*}" # extension removed |
#!/usr/bin/env bash | |
# | |
# ephemeral-port | |
# | |
# A script that returns a random *unused* TCP port within the IANA-suggested | |
# ephemeral port range of 49152 to 65535. Defaults to checking the localhost, | |
# but takes an optional hostname as an argument. | |
# | |
# See: |
#!/usr/bin/env bash | |
current_branch=$(git symbolic-ref -q HEAD | sed -e 's|^refs/heads/||') | |
if [[ $current_branch = 'master' ]]; then | |
printf 'Direct commits to the master branch are not allowed.\n' | |
exit 1 | |
fi | |
if command -v yamllint > /dev/null; then |
#!/usr/bin/env bash | |
# ensure we were given two command line arguments | |
if [[ $# -ne 2 ]]; then | |
echo 'usage: vault-cp SOURCE DEST' >&2 | |
exit 1 | |
fi | |
source=$1 | |
dest=$2 |
Copyright (c) 2018, Aaron Bull Schaefer <[email protected]> | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in |
{ | |
packageOverrides = pkgs: rec { | |
ansible2 = pkgs.stdenv.lib.overrideDerivation pkgs.ansible2 (oldAttrs: rec { | |
variable = "2.1.4.0"; | |
name = "ansible-${variable}"; | |
src = pkgs.fetchurl { | |
url = "http://releases.ansible.com/ansible/${name}.tar.gz"; | |
sha256 = "05nc68900qrzqp88970j2lmyvclgrjki66xavcpzyzamaqrh7wg9"; | |
}; |
I've been asked a few times over the last few months to put together a full write-up of the Git workflow we use at RichRelevance (and at Precog before), since I have referenced it in passing quite a few times in tweets and in person. The workflow is appreciably different from GitFlow and its derivatives, and thus it brings with it a different set of tradeoffs and optimizations. To that end, it would probably be helpful to go over exactly what workflow benefits I find to be beneficial or even necessary.
#!/usr/bin/env bash | |
##### Functions | |
# print this script's usage message to stderr | |
usage() { | |
cat <<-EOF >&2 | |
usage: vagrant-box-clean [-p PREFIX] [-d] [-h] | |
EOF | |
} |
defmodule HttpRequester do | |
use GenServer | |
def start_link(_) do | |
GenServer.start_link(__MODULE__, nil, []) | |
end | |
def fetch(server, url) do | |
# Don't use cast: http://blog.elixirsips.com/2014/07/16/errata-dont-use-cast-in-a-poolboy-transaction/ | |
timeout_ms = 10_000 |