mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-06 03:00:43 +00:00
Track build numbers in git so I can sync them across platforms
This commit is contained in:
parent
7c22916e79
commit
d51988a4ac
1
sleepyhead/build_number.h
Normal file
1
sleepyhead/build_number.h
Normal file
@ -0,0 +1 @@
|
||||
const int build_number = 1;
|
1
sleepyhead/scripts/build_number
Normal file
1
sleepyhead/scripts/build_number
Normal file
@ -0,0 +1 @@
|
||||
1
|
@ -8,6 +8,18 @@ else
|
||||
number=0
|
||||
fi
|
||||
|
||||
if [ ! -f $MY_PATH/../build_number.h ]
|
||||
then
|
||||
# This is needed to build, so make sure it's available
|
||||
echo "const int build_number = ""$number;" | tee $MY_PATH/../build_number.h
|
||||
fi
|
||||
|
||||
if [ ! -f "$MY_PATH/ReleaseManager" ]
|
||||
then
|
||||
# Script only needs running by Release Managers
|
||||
exit;
|
||||
fi
|
||||
|
||||
if [ "$1" == "release" ]
|
||||
then
|
||||
echo "Updating build number"
|
||||
@ -16,9 +28,4 @@ then
|
||||
echo "const int build_number = ""$number;" | tee $MY_PATH/../build_number.h
|
||||
else
|
||||
echo "Skipping build number update"
|
||||
# But create anyway if it doesn't exist
|
||||
if [ ! -f $MY_PATH/../build_number.h ]
|
||||
then
|
||||
echo "const int build_number = ""$number;" | tee $MY_PATH/../build_number.h
|
||||
fi
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user