Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Remote Modules
remote-module-template
Commits
1018b42e
Commit
1018b42e
authored
Jul 23, 2019
by
Guillaume Pasero
Browse files
CI: detect project name
parent
9d1abf1e
Changes
1
Hide whitespace changes
Inline
Side-by-side
ci.cmake
View file @
1018b42e
...
...
@@ -3,9 +3,9 @@
set
(
REMOTE_MODULE_SOURCE_DIR
${
CMAKE_CURRENT_LIST_DIR
}
)
set
(
ENV{LANG}
"C"
)
# Only ascii output
# Get
module
name
file
(
STRINGS
"
${
CMAKE_CURRENT_LIST_DIR
}
/
otb-module.cmake"
_module
_match REGEX
"
otb_module
*
\\
("
)
string
(
REGEX REPLACE
"
otb_module
*
\\
( *([a-zA-Z0-9]+)"
"
\\
1"
otb-module
${
_
module
_match
}
)
# Get
project
name
file
(
STRINGS
"
${
CMAKE_CURRENT_LIST_DIR
}
/
CMakeLists.txt"
_project
_match REGEX
"
^project
*
\\
("
)
string
(
REGEX REPLACE
"
^project
*
\\
( *([a-zA-Z0-9]+)"
"
\\
1"
otb-module
${
_
project
_match
}
)
# Build Configuration : Release, Debug..
if
(
ci_build_type
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment