Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Idea: Add `defaults` to `parse_params` #9

Open
bbros-dev opened this issue Mar 29, 2020 · 0 comments
Open

Idea: Add `defaults` to `parse_params` #9

bbros-dev opened this issue Mar 29, 2020 · 0 comments

Comments

@bbros-dev
Copy link

@bbros-dev bbros-dev commented Mar 29, 2020

Taking on board the feedback in PR #8, I'm feeding back some changes I've found useful.

For consideration:

# DESC: Variable defaults
# ARGS: None.
# OUTS: Variables with default values set.
function defaults() {
  verbose=false no_colour=false cron=false outfile=-
}

...

function parse_params() {
....
  local param
  defaults
  # now enjoy the options in order and nicely split until we see --
....
@bbros-dev bbros-dev changed the title Idea: Add `defaults` to parse_params() Idea: Add `defaults` to `parse_params` Mar 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.