Created
December 3, 2020 15:52
-
-
Save csalzano/f54d5d32405fc3cdc5f40addef0c7649 to your computer and use it in GitHub Desktop.
Zips a directory while excluding .git, node_modules, and .gitingore
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ::plugin-zipper.bat | |
| ::Zips a directory while excluding .git, node_modules, and .gitingore | |
| @echo off | |
| set /p slug=Please enter a directory name/plugin slug: | |
| If /I "%slug%"=="" goto earlyexit | |
| tar -a -c -f "%slug%".zip --exclude ".git" --exclude ".gitignore" --exclude "node_modules" "%slug%" | |
| :earlyexit |
Author
Author
Using git archive could make this platform agnostic https://stackoverflow.com/a/28357990/338432
Author
TODO, detect if the directory is a plugin or a theme
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Usage on Windows