forked from musescore/MuseScore
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improve handling of mscore/revision.h
Added a default mscore/revision.h containing "Unknown" as the revision number (mscore/revision.h remains in .gitignore). Removed the dependency on "revision" in the Makefiles. Now "make revision" must be done manually if required. Added sample post-checkout git hook to allow git automatically to update mscore/revision.h when doing a git checkout. If installed, this removes the need to do "make revision" manually.
- Loading branch information
Showing
5 changed files
with
19 additions
and
6 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
Copy the post-checkout file from build/git/hooks/ into .git/hooks/ in order | ||
for git to update mscore/revision.h with the branch number automatically when | ||
checking out: | ||
|
||
$ cp -p build/git/hooks/post-checkout .git/hooks/ | ||
|
||
This only needs doing once, and then removes the need to do "make revision" | ||
manually for setting the correct revision number after doing a checkout. | ||
|
||
This works for Linux, Windows (MinGW) and OSX. |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#!/bin/sh | ||
git rev-parse --short HEAD >mscore/revision.h |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
Unknown |