Find file
Fetching contributors…
Cannot retrieve contributors at this time
executable file 5 lines (4 sloc) 196 Bytes
#!/usr/bin/env bash
# strips newlines, line comments and whitespace at beginning of lines.
# usage: ./make_bookmarklet.sh bookmarklet_file
cat $1 | grep -v '^//.*$' | sed 's/^\s*/ /' | tr -d '\n'