Skip to content
New issue

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

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

Already on GitHub? # to your account

Hacky workaround for optparse-applicative issue with stack exec --help #903

Merged
merged 2 commits into from
Sep 2, 2015

Conversation

snoyberg
Copy link
Contributor

@snoyberg snoyberg commented Sep 2, 2015

Fixes #806

Downside: usage information now looks like:

Usage: stack exec [CMD -- ARGS (e.g. stack ghc -- X.hs -o x)]

Notice how "CMD" is inside the square brackets. Still seems like a
worthwhile tradeoff to me.

fixes #806)

Downside: usage information now looks like:

Usage: stack exec [CMD -- ARGS (e.g. stack ghc -- X.hs -o x)]

Notice how "CMD" is inside the square brackets. Still seems like a
worthwhile tradeoff to me.
@chrisdone
Copy link
Member

Took me a while to understand what this patch does. I see the problem it solves is stack exec CMD requires CMD to be passed regardless of any other options, so stack exec foo --help will print the help, but stack exec --help complains, in its stupid way, that CMD is missing (but actually says "--help is an invalid option").

borsboom added a commit that referenced this pull request Sep 2, 2015
Hacky workaround for optparse-applicative issue with stack exec --help
@borsboom borsboom merged commit c17c5a6 into master Sep 2, 2015
@borsboom
Copy link
Contributor

borsboom commented Sep 2, 2015

Merged this, but I think I'll keep the original issue open for now in the hopes of finding a non-hacky way to fix it.

@dysinger dysinger deleted the 806-exec-help-hack branch April 7, 2016 00:55
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants