Skip to content

Instantly share code, notes, and snippets.

@andrewp-as-is
Created August 11, 2019 13:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewp-as-is/42dba0c1ba63652f67fe898ae06514f3 to your computer and use it in GitHub Desktop.
Save andrewp-as-is/42dba0c1ba63652f67fe898ae06514f3 to your computer and use it in GitHub Desktop.
tar
#!/usr/bin/env bash
path=~/Desktop
tar -czf name.tar.gz -C "$path" .
# find . -type f ! -name $'Icon\r' > "$FILES_FROM" || exit;
# set -- tar -czf "$LocalPath" -T "$FILES_FROM"
# [ -s "$EXCLUDE_FROM" ] && set -- "$@" -X "$EXCLUDE_FROM"
# extract
tar -xf name.tar.gz -C /target/directory
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment