Last active
September 23, 2020 13:18
-
-
Save pfrozi/8441b138c2abf56b81a97c4d1cfd5811 to your computer and use it in GitHub Desktop.
Create a SQL Server script with all new .sql files from branch_with_new_scripts
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
#!/bin/bash | |
script=scripts_complete.sql | |
rm -f $script | |
for item in $(git diff-tree --name-only --no-commit-id -r master branch_with_new_scripts | grep ".sql"); do | |
cat $item >> $script | |
echo >> $script | |
echo GO >> $script | |
echo >> $script | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment