Skip to content

Instantly share code, notes, and snippets.

@mauroartizzu
Last active September 6, 2018 21:00
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 mauroartizzu/56800f5e14ad938af136d6198bd6cada to your computer and use it in GitHub Desktop.
Save mauroartizzu/56800f5e14ad938af136d6198bd6cada to your computer and use it in GitHub Desktop.
[Tar-Zip Current Commit Hash] Tar-Zip Recursively excluding folders with current commit filename #tar #zip #git #commit
tar --exclude='*.git' --exclude='node_modules' --exclude='vendor' -zcvf `git rev-parse HEAD`.tgz *
zip -r `git rev-parse HEAD`.zip . -x *.git* vendor/\* node_modules/\* *.idea* *.vscode* *.sonarlint*
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment