Skip to content

Instantly share code, notes, and snippets.

@erichs
Last active January 21, 2018 19:10
Show Gist options
  • Select an option

  • Save erichs/9cb8986fcd2bd4c11217 to your computer and use it in GitHub Desktop.

Select an option

Save erichs/9cb8986fcd2bd4c11217 to your computer and use it in GitHub Desktop.
Improved Shell script with binary data
#!/bin/bash
{
cd /path/to/unzip || exit
while read line; do
case $line in
"exit 0") break;;
esac
done
tar zxf -
} < "$0"
exit 0
<...binary data here...>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment