Coder Social home page Coder Social logo

boeingx / docker-haskell-vim Goto Github PK

View Code? Open in Web Editor NEW
6.0 1.0 0.0 977 KB

Vim with Haskell support on Docker

License: GNU General Public License v3.0

Vim Script 69.01% Shell 11.34% Dockerfile 19.65%
vim haskell docker vim8 development-tools autocomplete syntax-highlighting

docker-haskell-vim's Introduction

Build Status

What is this?

haskell-vim is a docker-based Haskell development environment with Vim 8.x. It comes with syntax highlighting and code completion powered by Haskell IDE Engine).

Why?

Vim is a highly configurable, light-weight editor extremely suitable for programming in Haskell. Compare to heavy IDEs like Eclipse, one does not need to create a project etc. before writing any code. Since the release of version 8.0, it ships an embedded terminal emulator.

Haskell IDE Engine is an excellent Language Server Protocol client compatible with GHC 8.4.3.

However, it is sometimes tricky to get it work with Vim because of the deoplete.nvim plugin. Indeed, this plugin requires Vim to be built with python3 support which is not always the case.

For example, on my Arch Linux machine, gvim is built with python3/dyn so I failed to get deoplete to work :(

With haskell-vim, everything just works out of box: syntax highlighting, code completion etc, and one can thus concentrate on learning and developing in Haskell.

How to launch?

Build from source

cd docker && docker build -t haskell-vim .

Please note that a fresh build will take a LONG time (50+ minutes on my laptop) and consumes many RAM, so be patient :)

Pull from docker hub (recommended)

Run

docker run -it --rm -v <local/path/to/workdir/>:/workspace boeingx/haskell-vim bash

The above command maps a local folder <local/path/to/workdir/> to the default work directory /home/haskell/workspace in order to have persistent data.

Screenshots

Built-in terminal

terminal

Autocompletion

autocompletion

Show documentation, goto definition and rename

hover

Troubleshooting

When build docker image, I get an error saying Process exited with code: ExitFailure (-9) (THIS MAY INDICATE OUT OF MEMORY)

As the error message indicates, this is due to an out of memory. Verify that you have at least 4Gb RAM available.

If you use docker on Windows or Mac OS, edit the preference so that docker could use more memory. See this discussion

docker-haskell-vim's People

Contributors

boeingx avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.