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

Adds --numeric-version and --ghc-numeric-version #158

Closed
wants to merge 2 commits into from

Conversation

angerman
Copy link

@angerman angerman commented May 3, 2017

This allows to parse the ghc version from doctest with any parser
that can parse ghc --version already.

Fixes #157

This allows to parse the ghc version from doctest with any parser
that can parse `ghc --version` already.
@angerman
Copy link
Author

angerman commented May 3, 2017

I'm not sure if we really want this. As doctest --version already provides this information. See

$ doctest --version
doctest version 0.11.2
using version 8.3.20170502 of the GHC API
using /Users/angerman/mobile-ghc/bin/ghc-8.3.20170502

This though would provide it in the identical format the ghc --version provides it:

$ doctest --ghc-version
The Glorious Glasgow Haskell Compilation System, version 8.3.20170502
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 8.3.20170502

@phadej
Copy link
Contributor

phadej commented May 3, 2017

I'd output just a 8.3.20170502 so the output can be used by other tooling.

EDIT compare how stack has stack --hpack-numeric-version; maybe the flag should be --ghc-numeric-version ?

EDIT and should there be bare --numeric-version which would output 0.11.2 doctest version string

@angerman
Copy link
Author

angerman commented May 3, 2017

Alright that's more sensible (to me at least):

$ doctest --ghc-numeric-version
8.3.20170502
$ doctest --numeric-version
0.11.2

@angerman angerman changed the title Adds --ghc-version Adds --numeric-version and --ghc-numeric-version May 3, 2017
@phadej
Copy link
Contributor

phadej commented May 3, 2017

👍

@sol
Copy link
Owner

sol commented May 4, 2017

I'm closing this in favor of #159 (I prefer --info, analogous to ghc --info).

@sol sol closed this May 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants