Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
gargantext-ihaskell
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
gargantext-ihaskell
Commits
ed3b892e
Commit
ed3b892e
authored
Feb 13, 2016
by
Nicholas Luo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use Paths_ihaskell provided by cabal to get IHaskell version number
parent
b2c8b1f0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
Main.hs
main/Main.hs
+7
-3
No files found.
main/Main.hs
View file @
ed3b892e
...
...
@@ -28,6 +28,7 @@ import System.Posix.Signals
import
qualified
Data.Map
as
Map
import
qualified
Data.Text.Encoding
as
E
import
Data.List
(
break
,
last
)
import
Data.Version
(
showVersion
)
-- IHaskell imports.
import
IHaskell.Convert
(
convert
)
...
...
@@ -46,6 +47,9 @@ import IHaskell.IPython.Types
import
qualified
IHaskell.IPython.Message.UUID
as
UUID
import
qualified
IHaskell.IPython.Stdin
as
Stdin
-- Cabal imports.
import
Paths_ihaskell
(
version
)
-- GHC API imports.
import
GHC
hiding
(
extensions
,
language
)
...
...
@@ -86,7 +90,7 @@ showDefault :: String -> [Argument] -> IO ()
showDefault
helpStr
flags
=
case
find
(
==
Version
)
flags
of
Just
_
->
putStrLn
VERSION_ipython_kernel
putStrLn
(
showVersion
version
)
Nothing
->
putStrLn
helpStr
...
...
@@ -248,9 +252,9 @@ replyTo _ KernelInfoRequest{} replyHeader state =
(
state
,
KernelInfoReply
{
header
=
replyHeader
,
protocolVersion
=
"5.0"
,
banner
=
"IHaskell "
++
VERSION_ipython_kernel
++
" GHC "
++
VERSION_ghc
,
banner
=
"IHaskell "
++
(
showVersion
version
)
++
" GHC "
++
VERSION_ghc
,
implementation
=
"IHaskell"
,
implementationVersion
=
VERSION_ipython_kernel
,
implementationVersion
=
showVersion
version
,
languageInfo
=
LanguageInfo
{
languageName
=
"haskell"
,
languageVersion
=
VERSION_ghc
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment