Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Figure out or own version

  • Loading branch information...
commit cbe0f7bc5ddae7f546e525394c8095062e11ef0f 1 parent af54fd0
Jasper Van der Jeugt authored
Showing with 8 additions and 2 deletions.
  1. +1 −1  .ghci
  2. +6 −1 src/Main.hs
  3. +1 −0  stylish-haskell.cabal
2  .ghci
View
@@ -1 +1 @@
-:set -isrc -itests -idraft
+:set -isrc -itests -idist/build/autogen
7 src/Main.hs
View
@@ -6,11 +6,14 @@ module Main
--------------------------------------------------------------------------------
+import Data.List (intercalate)
import Data.Maybe (listToMaybe)
+import Data.Version (Version(..))
import System.Console.CmdArgs
--------------------------------------------------------------------------------
+import Paths_stylish_haskell (version)
import StylishHaskell
import StylishHaskell.Config
@@ -27,7 +30,9 @@ stylishArgs :: StylishArgs
stylishArgs = StylishArgs
{ config = Nothing &= typFile &= help "Configuration file"
, files = [] &= typFile &= args
- } &= summary "stylish-haskell"
+ } &= summary ("stylish-haskell-" ++ versionString version)
+ where
+ versionString = intercalate "." . map show . versionBranch
--------------------------------------------------------------------------------
1  stylish-haskell.cabal
View
@@ -24,6 +24,7 @@ Executable stylish-haskell
Main-is: Main.hs
Other-modules:
+ Paths_stylish_haskell
StylishHaskell
StylishHaskell.Block
StylishHaskell.Config
Please sign in to comment.
Something went wrong with that request. Please try again.