Closed nvnieuwk closed 3 months ago
Nice! Could we test it with the
nf-core/testpipeline
to make sure that the current functionality can be replicated?
I used a version of the test pipeline to test out these features but I'll try it out on a new branch of the repo too :)
I'll go ahead and merge this into the other PR now :) Thanks for the reviews!
This PR completely revamps the help messages.
List of changes:
paramsHelp
function. TheparamsHelp
function is still present for backwards compatibility but will no longer be updated. A deprecation warning will also be printed now to prompt the users to migrate to the new system. (Is there a need to keep this function fully supported?)validation.help.enabled
: Will check if the help parameters are given and print out the correct help messagevalidation.help.shortParameter
: Change the parameter to use for the compact help message (--help
by default)validation.help.fullParameter
: Change the parameter to use for the full help message (--helpFull
by default)validation.help.showHiddenParameter
: Change the parameter to show hidden parameters in the help message (--showHidden
by default)validation.help.beforeText
: Provides a way to add some custom text before the help messagevalidation.help.afterText
: Provides a way to add some custom text after the help messagevalidation.help.command
: Will add an example command to the help messagevalidation.help.showHidden
: Enabling this options will make sure that the help message will also contain hidden parameters by default. This option replacesvalidation.showHiddenParameters
, which will keep working for now but will also show a deprecation message.--help
=> A help message with the non-nested parameters (Styling has not been applied on this example, comments (#
) are also not in the real output)Grouped Parameters
Input/output options --input [string] Path to comma-separated file containing information about the samples in the experiment. --nested_params [object] This is a nested parameter (This parameter has sub-parameters. Use '--help nested_params' to see all sub-parameters)
--nested_params description: This is a nested parameter options : --nested_params.deep.hello [string] hi --nested_params.deep.bool [boolean] boolean value --nested_params.bye [string] This is goodbye
--testparams.test [integer]
Input/output options --input [string] Path to comma-separated file containing information about the samples in the experiment. --nested_params.deep.hello [string] hi --nested_params.deep.bool [boolean] boolean value --nested_params.bye [string] This is goodbye