• Stars
    star
    25
  • Rank 926,117 (Top 19 %)
  • Language
    Emacs Lisp
  • License
    GNU General Publi...
  • Created about 5 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Automatic Haskell setup in Emacs, for Nix users

nix-haskell-mode

https://melpa.org/packages/nix-haskell-mode-badge.svg

nix-haskell-mode is an easy way to get Haskell projects set up in Emacs. It uses haskell-mode’s interactive-haskell-mode to provide integration with Emacs. Nix is used to pull in dependencies of each Cabal file.

To use with use-package, just add this to your configuration,

(use-package nix-haskell-mode
  :hook (haskell-mode . nix-haskell-mode))

nix-haskell-mode is available in MELPA. You can install it yourself with M-x package-install nix-haskell-mode. Alternative configuration for vanilla Emacs is available below,

(require 'haskell-mode)
(require 'nix-haskell-mode)
(add-hook 'haskell-mode-hook 'nix-haskell-mode)

This configuration should work out of the box with Cabal projects. If you have custom dependencies that need to be available, you should create override in Haskell packages in Nix. More documentation on this is available in the Nixpkgs manual available here:

https://nixos.org/nixpkgs/manual/#users-guide-to-the-haskell-infrastructure

Affected modes

These modes are affected by nix-haskell-mode. They are listed below along with what variables are set by nix-haskell-mode.

  • Flycheck - sets flycheck-ghc-package-databases and flycheck-haskell-ghc-executable.
  • Haskell Mode - sets haskell-process-type to cabal-new-repl, haskell-process-path-cabal, haskell-process-args-cabal-new-repl.

Project information

This project is available at http://github.com/matthewbauer/nix-haskell-mode. Pull requests and issues are accepted.

Disabling nix-haskell-mode for a project

Occasionally you will want to disable nix-haskell-mode. This might occur in very large projects where interactive-haskell-mode fails at or when some dependency cannot be fetched succesfully. In these cases, you should run the following in the root of your project:

=M-x add-dir-local-variable<RET>haskell-mode<RET>eval<RET>(nix-haskell-mode -1)<RET>=

More Repositories

1

nix-bundle

Bundle Nix derivations to run anywhere!
Nix
593
star
2

bauer

An Emacs+Nix IDE
Emacs Lisp
107
star
3

nixiosk

Declarative Kiosk systems built with NixOS
Nix
106
star
4

ghc-nix

Exploring the options for incremental Haskell builds using Nix
Haskell
105
star
5

gametime-player

A super simple JS-based libretro frontend
CoffeeScript
38
star
6

unipkg

Create a package for different distros using a single PKGBUILD file (unmaintained)
Shell
31
star
7

undmg

extract a dmg file
C
26
star
8

rivulet

a simple, fast, open source RSS reader
Go
21
star
9

reddwall

Change your background to a random wallpaper on Reddit.
Python
20
star
10

resume

my résumé
TeX
19
star
11

retrojs

Libretro emulator cores compiled into modular JavaScript.
JavaScript
17
star
12

eu4-parser

some tools to parse files from the clausewitz engine
Haskell
14
star
13

static-nix

Statically built Nix binaries
Nix
14
star
14

nixos-kiosk

NixOS kiosk using Cage
Nix
10
star
15

caldav-to-gtasks

A caldav server that writes directly to Google Tasks
Python
9
star
16

uzbl-os

A Uzbl based distro, similar to Google Chrome OS
Python
8
star
17

libmii

Wii homebrew library for Miis
C
7
star
18

macNixOS

a set of useful things for running Nix on macOS
Shell
4
star
19

x-retro

<x-retro></x-retro>
CoffeeScript
4
star
20

uzbl-extension-manager

A simple extension manager for Uzbl
Shell
4
star
21

metapkgs

A set of package sets
Nix
4
star
22

gpemu2

libretro frontend written in Haskell and Reflex
Haskell
3
star
23

make-package

Nix
3
star
24

counter

Counter app for the Pebble watch
C
3
star
25

xilium.cefglue

GitHub mirror of xilium.cefglue
C#
3
star
26

matthewbauer.github.io

My personal site
Shell
2
star
27

unipkg-pacman

C
2
star
28

nur-packages

Nix
2
star
29

denali

Denali Linux - NixOS for humans
Nix
2
star
30

node-retro

THIS REPO IS DEPRECATED!!! Use retrojs instead.
C
2
star
31

auto-update-flake

GitHub Action to automatically update flake inputs if they pass CI
2
star
32

todo.txt-gtk

Graphical User Interface for todo.txt in Python
Python
2
star
33

65536

CSS
1
star
34

vector-algorithms

Haskell
1
star
35

skeleton

Haskell
1
star
36

exdongle

provides 'AutoRun' capabilities to Linux systems (based on a script by Gogodidi)
1
star
37

xib2nib

C++
1
star
38

hangman

Really hard hangman game in HTML and Javascript
JavaScript
1
star
39

snes-info

command line tool to get information on the header of SNES .SMC files
Go
1
star
40

hbb-medawiki

Homebrew Browser Mediawiki extensions to allow repository editing from a wiki
PHP
1
star
41

dot-emacs

Emacs Lisp
1
star
42

jaycal

Automagically generate a calendar using your university account.
JavaScript
1
star