Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
PeTrack
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Pedestrian Dynamics Empiricism
PeTrack
Commits
9949e9e7
Commit
9949e9e7
authored
3 years ago
by
Tobias Schroedter
Committed by
Schrödter, Tobias
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Update check for git repo
parent
109786db
No related branches found
No related tags found
1 merge request
!114
Update check for git repo
Pipeline
#39129
passed
3 years ago
Stage: build
Stage: test
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
cmake_modules/helper_functions.cmake
+4
-4
4 additions, 4 deletions
cmake_modules/helper_functions.cmake
with
4 additions
and
4 deletions
cmake_modules/helper_functions.cmake
+
4
−
4
View file @
9949e9e7
...
...
@@ -22,10 +22,10 @@ function(get_git_info)
# VCS info
################################################################################
find_package
(
Git QUIET
)
find_program
(
GIT_SCM git DOC
"Git version control"
)
mark_as_advanced
(
GIT_SCM
)
find_file
(
GITDIR NAMES .git PATHS
${
CMAKE_SOURCE_DIR
}
NO_DEFAULT_PATH
)
if
(
GIT_SCM AND GITDIR
)
# Returns 0 if the given directory is a git repo
execute_process
(
COMMAND
"
${
GIT_EXECUTABLE
}
"
-C
"
${
CMAKE_SOURCE_DIR
}
"
rev-parse RESULT_VARIABLE in_git_repo
)
if
(
in_git_repo EQUAL
"0"
)
# the commit's SHA1, and whether the building workspace was dirty or not
# describe --match=NeVeRmAtCh --always --tags --abbrev=40 --dirty
execute_process
(
COMMAND
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment