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 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 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
plugin-zipper.sh
a Unix-like system equivalent
Puts version numbers in file names
A plugin with slug
term-meta-ui
will zip into a folder named term-meta-ui-v0.4.0.zip.Usage
[~/]$ bash plugin-zipper.sh term-meta-ui