Skip to content

Consider passing raw command line args to initialize.sh for early processing/parsing.  #685

@surgiie

Description

@surgiie

Description

Some scripts or CLIs may need to parse command-line arguments/options during early initialization (in initialize.sh). Currently, since the initialize function is called with no arguments, things like $# is 0 and $@ is empty at that point. Additionally, $args hasn't been parsed yet during early initialization, making the raw arguments inaccessible.

Could we pass the arguments to initialize to enable early parsing? For example:

command_line_args=("$@")
initialize "${command_line_args[@]}"  # pass args for early access if needed
run "${command_line_args[@]}"

Is there any reason not to do this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionRequest for help or general question

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions