mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-04 22:19:02 +00:00
* Restore GIT_BRANCH Removed by mistake on previous commit * Fix commit count on AppVeyor builds
This commit is contained in:
parent
6b323d7e2e
commit
60f5929f81
2 changed files with 11 additions and 17 deletions
|
|
@ -19,20 +19,13 @@ if(GIT_FOUND AND EXISTS "${SOURCE_DIR}/../.git/")
|
|||
if(NOT ${exit_code} EQUAL 0)
|
||||
message(WARNING "git rev-parse failed, unable to include version.")
|
||||
endif()
|
||||
# (Unused code, we're currently building with MSVC on AppVeyor)
|
||||
# Hack fix for AppVeyor (Pull Requests don't generate a branch name)
|
||||
#
|
||||
# if(NOT DEFINED ENV{APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH})
|
||||
# execute_process(COMMAND ${GIT_EXECUTABLE} rev-parse --abbrev-ref HEAD
|
||||
# WORKING_DIRECTORY ${SOURCE_DIR}
|
||||
# RESULT_VARIABLE exit_code
|
||||
# OUTPUT_VARIABLE GIT_BRANCH)
|
||||
# if(NOT ${exit_code} EQUAL 0)
|
||||
# message(WARNING "git rev-parse failed, unable to include git branch.")
|
||||
# endif()
|
||||
# else()
|
||||
# set(GIT_BRANCH $ENV{APPVEYOR_PULL_REQUEST_HEAD_REPO_BRANCH})
|
||||
# endif()
|
||||
execute_process(COMMAND ${GIT_EXECUTABLE} rev-parse --abbrev-ref HEAD
|
||||
WORKING_DIRECTORY ${SOURCE_DIR}
|
||||
RESULT_VARIABLE exit_code
|
||||
OUTPUT_VARIABLE GIT_BRANCH)
|
||||
if(NOT ${exit_code} EQUAL 0)
|
||||
message(WARNING "git rev-parse failed, unable to include git branch.")
|
||||
endif()
|
||||
string(STRIP ${GIT_VERSION} GIT_VERSION)
|
||||
string(STRIP ${GIT_VERSION_} GIT_VERSION_)
|
||||
string(STRIP ${GIT_VERSION}-${GIT_VERSION_} GIT_VERSION)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue