Improve portability

This commit is contained in:
Shohei YOSHIDA 2026-03-26 13:52:05 +09:00
parent 5993fc38e7
commit a5d34d3aef
No known key found for this signature in database
GPG Key ID: C9A1BB11BB940CF2
2 changed files with 7 additions and 7 deletions

View File

@ -40,7 +40,7 @@ _cpack() {
_arguments \ _arguments \
'-G[Override/define CPACK_GENERATOR]:generator:_cpack_generators' \ '-G[Override/define CPACK_GENERATOR]:generator:_cpack_generators' \
'-C[Specify the project configurations]:configuration:(Debug Release)' \ '-C[Specify the project configurations]:configuration:(Debug Release)' \
*'-D[Set a CPack variable]:var_val' \ '*-D[Set a CPack variable]:var_val' \
'--config[Specify the config file]:file:_files' \ '--config[Specify the config file]:file:_files' \
'(-V --verbose)'{-V,--verbose}'[Enable verbose output]' \ '(-V --verbose)'{-V,--verbose}'[Enable verbose output]' \
'--trace[Put underlying cmake scripts in trace mode]' \ '--trace[Put underlying cmake scripts in trace mode]' \
@ -116,7 +116,7 @@ _cpack_generators() {
} }
_cpack_help_manuals() { _cpack_help_manuals() {
local -a manuals=(${(f)"$(cpack --help-manual-list 2>/dev/null | sed 's/([0-9]\+)$//' )"}) local -a manuals=(${(f)"$(cpack --help-manual-list 2>/dev/null | sed 's/([0-9][0-9]*)$//' )"})
_values 'manual' $manuals _values 'manual' $manuals
} }

View File

@ -64,7 +64,7 @@ _ctest() {
\*{-FS,--fixture-exclude-setup}'[Do not automatically add setup tests for fixtures matching regular expression]:regex' \ \*{-FS,--fixture-exclude-setup}'[Do not automatically add setup tests for fixtures matching regular expression]:regex' \
\*{-FC,--fixture-exclude-cleanup}'[Do not automatically add cleanup tests for fixtures matching regular expression]:regex' \ \*{-FC,--fixture-exclude-cleanup}'[Do not automatically add cleanup tests for fixtures matching regular expression]:regex' \
'(--dashboard)'{-D,--dashboard}'[Execute dashboard test]:dashboard' \ '(--dashboard)'{-D,--dashboard}'[Execute dashboard test]:dashboard' \
*'-D[Define a variable for script mode]:var' \ '*-D[Define a variable for script mode]:var' \
'(-M --test-model)'{-M,--test-model}'[Set the model for a dashboard]:model' \ '(-M --test-model)'{-M,--test-model}'[Set the model for a dashboard]:model' \
'(-T --test-action)'{-T,--test-action}'[Set the dashboard action to perform]' \ '(-T --test-action)'{-T,--test-action}'[Set the dashboard action to perform]' \
'--group[Specify what build group on the dashboard]:group' \ '--group[Specify what build group on the dashboard]:group' \
@ -84,7 +84,7 @@ _ctest() {
'--no-subproject-summary[Disable timing summary information for subprojects]' \ '--no-subproject-summary[Disable timing summary information for subprojects]' \
'--test-dir[Specify the directory in which to look for tests]:dir:_files -/' \ '--test-dir[Specify the directory in which to look for tests]:dir:_files -/' \
'--build-and-test[Configure, build and run a test]' \ '--build-and-test[Configure, build and run a test]' \
*'--build-target[Specify a specific target to build]:target' \ '*--build-target[Specify a specific target to build]:target' \
'--build-nocmake[Run the build without running cmake first]' \ '--build-nocmake[Run the build without running cmake first]' \
'--build-run-dir[Specify directory to run programs from]:dir:_files -/' \ '--build-run-dir[Specify directory to run programs from]:dir:_files -/' \
'--build-two-config[Run CMake twice]' \ '--build-two-config[Run CMake twice]' \
@ -96,14 +96,14 @@ _ctest() {
'--build-makeprogram[Specify the make program to use]:make:_files' \ '--build-makeprogram[Specify the make program to use]:make:_files' \
'--build-noclean[Skip the make clean step]' \ '--build-noclean[Skip the make clean step]' \
'--build-config-sample[A sample executable to use to determine the configuration]:sample' \ '--build-config-sample[A sample executable to use to determine the configuration]:sample' \
*'--build-options[Add extra options to the build step]' \ '*--build-options[Add extra options to the build step]' \
'--test-command[The test to run with the --build-and-test-option]:command' \ '--test-command[The test to run with the --build-and-test-option]:command' \
'--test-timeout[The time limit in seconds]:timeout' \ '--test-timeout[The time limit in seconds]:timeout' \
'--test-load[CPU load threshold for starting new parallel tests]:threshold' \ '--test-load[CPU load threshold for starting new parallel tests]:threshold' \
'--tomorrow-tag[starts with next day tag]' \ '--tomorrow-tag[starts with next day tag]' \
'--overwrite[Overwrite CTest configuration option]' \ '--overwrite[Overwrite CTest configuration option]' \
'--extra-submit[Submit extra files to the dashboard]:file:_files' \ '--extra-submit[Submit extra files to the dashboard]:file:_files' \
*'--http-header[Append HTTP header when submitting]:header' \ '*--http-header[Append HTTP header when submitting]:header' \
'--schedule-random[Use a random order for scheduling tests]' \ '--schedule-random[Use a random order for scheduling tests]' \
'--schedule-random-seed[Override seed for random order of tests]:seed' \ '--schedule-random-seed[Override seed for random order of tests]:seed' \
'--submit-index[Submit individual dashboard tests with specific index]:index' \ '--submit-index[Submit individual dashboard tests with specific index]:index' \
@ -139,7 +139,7 @@ _ctest() {
} }
_ctest_help_manuals() { _ctest_help_manuals() {
local -a manuals=(${(f)"$(ctest --help-manual-list 2>/dev/null | sed 's/([0-9]\+)$//' )"}) local -a manuals=(${(f)"$(ctest --help-manual-list 2>/dev/null | sed 's/([0-9][0-9]*)$//' )"})
_values 'manual' $manuals _values 'manual' $manuals
} }