• Home
  • Raw
  • Download

Lines Matching +full:- +full:- +full:prefix

16 #  This file was originally developed by Jean-Christophe Fillion-Robin, Kitware Inc.
17 # and was partially funded by NIH grant 3P41RR013218-12S1
19 # AG 2013-02-18: I got it from here
27 # GIT_EXECUTABLE - path to git command line client
28 # GIT_FOUND - true if the command line client was found
31 # GIT_WC_INFO(<dir> <var-prefix>)
36 # <var-prefix>_WC_REVISION_HASH - Current SHA1 hash
37 # <var-prefix>_WC_REVISION - Current SHA1 hash
38 # <var-prefix>_WC_REVISION_NAME - Name associated with <var-prefix>_WC_REVISION_HASH
39 # <var-prefix>_WC_URL - output of command `git config --get remote.origin.url'
40 # <var-prefix>_WC_ROOT - Same value as working copy URL
41 # <var-prefix>_WC_GITSVN - Set to false
43 # ... and also the following ones if it's a git-svn repository:
44 # <var-prefix>_WC_GITSVN - Set to True if it is a
45 # <var-prefix>_WC_INFO - output of command `git svn info'
46 # <var-prefix>_WC_URL - url of the associated SVN repository
47 # <var-prefix>_WC_ROOT - root url of the associated SVN repository
48 # <var-prefix>_WC_REVISION - current SVN revision number
49 # <var-prefix>_WC_LAST_CHANGED_AUTHOR - author of last commit
50 # <var-prefix>_WC_LAST_CHANGED_DATE - date of last commit
51 # <var-prefix>_WC_LAST_CHANGED_REV - revision of last commit
52 # <var-prefix>_WC_LAST_CHANGED_LOG - last log of base revision
89 macro(GIT_WC_INFO dir prefix)
90 execute_process(COMMAND ${GIT_EXECUTABLE} rev-parse --verify -q --short=7 HEAD
93 OUTPUT_VARIABLE ${prefix}_WC_REVISION_HASH
95 set(${prefix}_WC_REVISION ${${prefix}_WC_REVISION_HASH})
97 …message(SEND_ERROR "Command \"${GIT_EXECUTBALE} rev-parse --verify -q --short=7 HEAD\" in director…
99 execute_process(COMMAND ${GIT_EXECUTABLE} name-rev ${${prefix}_WC_REVISION_HASH}
101 OUTPUT_VARIABLE ${prefix}_WC_REVISION_NAME
105 execute_process(COMMAND ${GIT_EXECUTABLE} config --get remote.origin.url
107 OUTPUT_VARIABLE ${prefix}_WC_URL
110 set(${prefix}_WC_GITSVN False)
112 # Check if this git is likely to be a git-svn repository
113 execute_process(COMMAND ${GIT_EXECUTABLE} config --get-regexp "^svn-remote"
120 # In case git-svn is used, attempt to extract svn info
125 OUTPUT_VARIABLE ${prefix}_WC_INFO
130 set(${prefix}_WC_GITSVN True)
132 "\\2" ${prefix}_WC_URL "${${prefix}_WC_INFO}")
134 "\\2" ${prefix}_WC_REVISION "${${prefix}_WC_INFO}")
136 "\\2" ${prefix}_WC_ROOT "${${prefix}_WC_INFO}")
138 "\\2" ${prefix}_WC_LAST_CHANGED_AUTHOR "${${prefix}_WC_INFO}")
140 "\\2" ${prefix}_WC_LAST_CHANGED_REV "${${prefix}_WC_INFO}")
142 "\\2" ${prefix}_WC_LAST_CHANGED_DATE "${${prefix}_WC_INFO}")
147 if(NOT ${prefix}_WC_URL)
149 set( ${prefix}_WC_URL "NA" )
151 set(${prefix}_WC_ROOT ${${prefix}_WC_URL})