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

refactor: pass request token as a flag instead of an argument #19

Merged
merged 1 commit into from Nov 17, 2018

Conversation

Projects
None yet
2 participants
@0xazure
Owner

0xazure commented Nov 5, 2018

Improves the calling convention to make the data passed more explicit and help clarify usage. This also has the added benefit of improving discoverability as we can generate autocomplete help from the flag to guide the correct usage.

The calling convention was:

supernova <username> [<auth-token>]

The calling convention is now:

supernova <username> [--token <token>]

Using clap also gives us help and version commands and display for free in addition to argument parsing.

Closes #16.

@0xazure 0xazure force-pushed the issues/16 branch 2 times, most recently from 430b096 to 8f71e6c Nov 5, 2018

refactor: pass request token as a flag instead of an argument
Improves the calling convention to make the data passed more explicit
and help clarify usage. This also has the added benefit of improving
discoverability as we can generate autocomplete help from the flag to
guide the correct usage.

The calling convention was:

`supernova <username> [<auth-token>]`

The calling convention is now:

`supernova <username> [--token <token>]`

Using clap also gives us help and version commands and display for free
in addition to argument parsing.

Closes #16.

@0xazure 0xazure force-pushed the issues/16 branch from 8f71e6c to 180ddf9 Nov 11, 2018

@0xazure

This comment has been minimized.

Owner

0xazure commented Nov 12, 2018

/cc @SeanPrashad can you give me a sanity check on this changeset?

It works as intended, I'm mostly just looking for suggestions on style (particularly that last into(), I still don't know how I feel about that).

@SeanPrashad

Looks fine to me - as @humphd says, "Make it work then make it fast" (or cleaner in this case) 😺

@0xazure 0xazure merged commit f4838f9 into master Nov 17, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@0xazure 0xazure deleted the issues/16 branch Nov 17, 2018

@0xazure 0xazure referenced this pull request Nov 25, 2018

Open

Barebones supernova UI #33

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