Skip to content

Can't read installed package list using ghc-pkg #129

Description

@OnkelTem

Hi,

I've installed the plugin from inside of PhpStorm. Then I've installed cabal and ghc-mod via stack:

stack -j1 install ghc-mod
stack -j1 install cabal-install

and configured the plugin correspondingly (set paths to cabal and ghc-mod/ghc-modi). Now when I open a tutorial project "helloworld" I see these two messages in the Event Log:

8:25:42 PM cabal: Can't read cabal package list.
8:25:42 PM cabal: Can't read installed package list using ghc-pkg.

What ghc-pkg? There seems to be no such an installation option. What am I supposed to do next?

I don't know whether the following is related to the above messages, probably not.

  1. I have errors in my code which is presumably correct (at least it is compiled fine using stack build). For example:
{-# LANGUAGE OverloadedStrings #-}
module Lib
    ( someFunc
    ) where

import qualified Data.Text.IO as T

someFunc :: IO ()
someFunc = T.putStrLn "someFunc"

— it has Data.Text.IO highlighted with the message: "Could not find module Data.Text.IO. Use -v to see a list of the files searched for".

  1. There seems to be no way to launch a program. Should I have Run button enabled or something?

  2. Also I don't see how to build a project from the IDE.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions