commercialhaskell / commercialhaskell/stack

stack ghci reads in ~/.ghci but does not set def: values

Open
#4,166 3 comments 0 reactions 0 assignees View on GitHub
further investigation required
Dominant language
Haskell
Stars
4.1k
Forks
850
Avg merge
10h 37m
Merged PRs (30d)
4

Description

### Steps to reproduce
from within a project root folder
```
> stack ghci
```
stack confirms it read the ~/.ghci file
screen shot 2018-07-19 at 1 17 57 pm

within ghci
```
:cmdName
```
screen shot 2018-07-19 at 1 20 22 pm

```
unknown command ':cmdName'.
```

Note:
stack ghci from my home directory works as expected. The `.ghci` file contents:
```
:set prompt "\ESC[0;34mλ> \ESC[m"
:def source readFile

-- Pretty printing of it
import IPPrint.Colored
:set -interactive-print=IPPrint.Colored.cpprint
:def cp (\_ -> return ":set -interactive-print=IPPrint.Colored.cpprint")
:def ncp (\_ -> return ":set -interactive-print=print")
```
### Expected
the commands executed within ghci to be recognized.

### Stack version
stack version 1.7.1
ghci version 8.4.3

### Method of installation
```
> stack build --compiler-tool ghci-pretty
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.