mirror of
https://github.com/danog/tgcalls_cli.git
synced 2024-11-26 20:15:19 +01:00
13 lines
437 B
CMake
13 lines
437 B
CMake
function(Prefix list prefix)
|
|
string(REGEX REPLACE "([^;]+)" "${prefix}\\1" newList "${${list}}")
|
|
set(${list} "${newList}" PARENT_SCOPE)
|
|
endfunction(Prefix)
|
|
|
|
function(Transform list regex replacement)
|
|
set(newList "")
|
|
foreach(line ${${list}})
|
|
string(REGEX REPLACE "${regex}" "${replacement}" newLine "${line}")
|
|
list(APPEND newList "${newLine}")
|
|
endforeach()
|
|
set(${list} "${newList}" PARENT_SCOPE)
|
|
endfunction(Transform) |