Skip to content

[FEATURE] Scripts with arguments should use getopts #2631

Closed

Description

@jajanusz

Is your feature request related to a problem? Please describe.
Manual parsing of arguments makes code harder to read can cause issues like one that is reported here: #2625

Describe the solution you'd like
Use getopts where applicable

Activity

  1. crazoes commented on Mar 26, 2020

    @crazoes
    Contributor

    @jajanusz @dbaluta I am working on this one.

  2. changed the title [-][FEATURE] Scripts with arguments should use getopt[/-] [+][FEATURE] Scripts with arguments should use getopt/getopts[/+] on Mar 26, 2020
  3. changed the title [-][FEATURE] Scripts with arguments should use getopt/getopts[/-] [+][FEATURE] Scripts with arguments should use getopts[/+] on Mar 26, 2020
  4. jajanusz commented on Mar 26, 2020

    @jajanusz
    ContributorAuthor

    @crazoes Thanks, I've updated description to use getopts instead of getopt, I think it's better cos it's in posix standard while getopt is not. Are you ok with that?

  5. jajanusz commented on Mar 26, 2020

    @jajanusz
    ContributorAuthor

    Also there is one script that uses it already:

    while getopts "t:c:r:j:v" OPTION; do

  6. kv2019i commented on Dec 17, 2025

    @kv2019i
    Collaborator

    No activity in 5 years, closing. Please reopen if still relevant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions