{ pkgs ? (import {}) , compilerName ? "ghc801" }: rec { # haskellPackages = pkgs.haskell.packages."${compilerName}"; haskellPackages = pkgs.haskell.packages."${compilerName}".override { overrides = self: super: { Shellac = pkgs.haskell.lib.appendPatch super.Shellac (pkgs.writeText "build.patch" '' From 20e394aa3ea287fcaacde9c076c9f49929b28ece Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Sat, 11 Jun 2016 22:06:36 +0200 Subject: [PATCH] Allow modification of state in beforePrompt --- src/System/Console/Shell/RunShell.hs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/System/Console/Shell/RunShell.hs b/src/System/Console/Shell/RunShell.hs index 79ffb54..3e0b95b 100644 --- a/src/System/Console/Shell/RunShell.hs +++ b/src/System/Console/Shell/RunShell.hs @@ -217,9 +217,11 @@ shellLoop desc backend iss = loop bst = backendState iss loop st = do - flushOutput backend bst + flushOutput backend bst + + runSh st (outputString backend bst) (beforePrompt desc) >>= loop' . fst - runSh st (outputString backend bst) (beforePrompt desc) + loop' st = do setAttemptedCompletionFunction backend bst (completionFunction desc backend bst st) -- 2.8.3 ''); }; }; sequence = haskellPackages.callPackage ./sequence.nix {}; }