ghcid: GHCi based bare bones IDE

[ bsd3, development, library, program ] [ Propose Tags ]

Either "GHCi as a daemon" or "GHC + a bit of an IDE". A very simple Haskell development tool which shows you the errors in your project and updates them whenever you save. Run ghcid --height=10 --command=ghci, where --height is the height of the console you will use, and --command is the command to start GHCi on your project.


[Skip to Readme]

Downloads

Note: This package has metadata revisions in the cabal description newer than included in the tarball. To unpack the package including the revisions, use 'cabal get'.

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.1, 0.1.1, 0.1.3, 0.2, 0.3, 0.3.1, 0.3.2, 0.3.3, 0.3.4, 0.3.5, 0.3.6, 0.4, 0.4.1, 0.4.2, 0.5, 0.5.1, 0.6, 0.6.1, 0.6.2, 0.6.3, 0.6.4, 0.6.5, 0.6.6, 0.6.7, 0.6.8, 0.6.9, 0.6.10, 0.7, 0.7.1, 0.7.2, 0.7.3, 0.7.4, 0.7.5, 0.7.6, 0.7.7, 0.8, 0.8.1, 0.8.2, 0.8.3, 0.8.4, 0.8.5, 0.8.6, 0.8.7, 0.8.8, 0.8.9
Change log CHANGES.txt
Dependencies base (>=4 && <5), cmdargs (>=0.10), directory (>=1.2), filepath, process (>=1.1), time [details]
License BSD-3-Clause
Copyright Neil Mitchell 2014
Author Neil Mitchell <ndmitchell@gmail.com>
Maintainer Neil Mitchell <ndmitchell@gmail.com>
Revised Revision 1 made by AdamBergmark at 2015-11-01T13:17:20Z
Category Development
Home page https://github.com/ndmitchell/ghcid#readme
Bug tracker https://github.com/ndmitchell/ghcid/issues
Source repo head: git clone https://github.com/ndmitchell/ghcid.git
Uploaded by NeilMitchell at 2014-09-27T20:43:35Z
Distributions Fedora:0.8.9, LTSHaskell:0.8.9, NixOS:0.8.9, Stackage:0.8.9
Reverse Dependencies 7 direct, 8 indirect [details]
Executables ghcid
Downloads 38715 total (197 in the last 30 days)
Rating 2.5 (votes: 5) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs not available [build log]
Last success reported on 2016-11-30 [all 6 reports]

Readme for ghcid-0.1.1

[back to package description]

ghcid Hackage version Build Status

Either "GHCi as a daemon" or "GHC + a bit of an IDE". Unlike other Haskell development tools, ghcid is intended to be incredibly simple. In particular, it doesn't integrate with any editors, doesn't depend on GHC the library and doesn't start web servers.

Using it

Run cabal update && cabal install ghcid to install it as normal. Then run ghcid --height=10 "--command=ghci Main.hs". The height is the number of lines you are going to resize your console window to (defaults to 8), and the command is how you start this project in ghci. Personally, I always create a .ghci file at the root of all my projects, which usually reads something like:

:set -fwarn-unused-binds -fwarn-unused-imports
:load Main

If you have that, then you can pass --command=ghci (or nothing, since that is the default).

After that, resize your console and make it so you can see it while working in your editor. On Windows the console will automatically sit on top of all other windows. On Linux, you probably want to use your window manager to make it topmost or use a tiling window manager.

What you get

On every save you'll see a list of the errors and warnings in your project. It uses ghci under the hood, so even relatively large projects should update their status pretty quickly. As an example:

Main.hs:23:10:
    Not in scope: `verbosit'
    Perhaps you meant `verbosity' (imported from System.Console.CmdArgs)
Util.hs:18:1: Warning: Defined but not used: `foo'

Or, if everything is good, you see:

All good

Please report any bugs you find.