Skip to content

Instantly share code, notes, and snippets.

Jesse Claven jesse-c

Block or report user

Report or block jesse-c

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@jesse-c
jesse-c / waitforandfollow.sh
Created Aug 1, 2017
Wait for Docker container to start and immediately follow its logs
View waitforandfollow.sh
#!/bin/bash -e
# Example:
#
# 1. In a terminal window: ./waitforandfollow.sh hello-world
# 2. In another terminal window: docker run hello-world
if [ "$#" -ne 1 ] ; then
echo "$0: exactly 1 argument expected."
exit 3
@jesse-c
jesse-c / crush.sh
Last active Aug 27, 2019
Use pngcrush to recursively optimise and replace PNGs (used on macOS)
View crush.sh
#!/bin/sh
find "$1" -type f -iname '*.png' -print0 | while IFS= read -r -d '' file; do
echo "crushing $file"
pngcrush -rem alla -reduce -brute "$file" temp.png
mv -f temp.png "$file"
done
You can’t perform that action at this time.