Created
November 11, 2023 18:49
-
-
Save michaelvolz/88aa1820aea826eef7e91ac472e7cbbe to your computer and use it in GitHub Desktop.
Git version number pre-commit hook
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
#!/bin/sh | |
echo "pre-commit started" | |
version=$(cat redmuffin.Blazor.Static/wwwroot/Version.txt); y=$((version=version+1)); echo $y > redmuffin.Blazor.Static/wwwroot/Version.txt | |
git add redmuffin.Blazor.Static/wwwroot/Version.txt | |
cat redmuffin.Blazor.Static/wwwroot/Version.txt | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment