Comments (24)
I can not reproduce this issue on Ubuntu. Which OS are you using?
Do you normally get type info in Haskell files?
from intellij-haskell.
Ubuntu 14.04. No, it might be that I didn't get your plugin running correctly yet. Although if I hover my cursor over another expression it seems not to show this error message at the very least. The ghc-modi version is 5.1.0.2 by the way. Is there some way I can verify whether I didn't activate something in the IDE or so?
from intellij-haskell.
Checks paths in Settings\Haskell
Did you create sandbox for your Haskell project? If not, I advice you to create sandbox.
I used latest version of ghc-mod (5.2.1.1) but that can not be the problem.
from intellij-haskell.
Btw, can you start ghc-modi in root directory of your project?
from intellij-haskell.
Yes, I can, like I said if I throw the commands that are reported as
failing into ghc-modi I get an answer from ghc-modi. Sometimes the answer
is that it cannot find something, but it doesn't time out like the error
message suggests.
Might it have something to do with subfolders? I have a subfolder in my
project and if I comment out the import B.C in my module A it stops
complaining about the ghc-modi stuff, seems to work (well, I get a warning
that it cannot find source code for System.Random in this case and to add
the source code of the package to Project Settings/LIbraries, I just point
it to my cabal sandbox to fix this?)
2014-11-13 17:33 GMT+01:00 Rik [email protected]:
Btw, can you start ghc-modi in root of your project?
—
Reply to this email directly or view it on GitHub
#2 (comment)
.
from intellij-haskell.
Can it have something to do with the fact that my ghc-mod is installed in
my ~/.cabal and the other stuff is in my cabal-sandbox in my project folder?
2014-11-14 9:12 GMT+01:00 Kasper Janssens <[email protected]
:
Yes, I can, like I said if I throw the commands that are reported as
failing into ghc-modi I get an answer from ghc-modi. Sometimes the answer
is that it cannot find something, but it doesn't time out like the error
message suggests.Might it have something to do with subfolders? I have a subfolder in my
project and if I comment out the import B.C in my module A it stops
complaining about the ghc-modi stuff, seems to work (well, I get a warning
that it cannot find source code for System.Random in this case and to add
the source code of the package to Project Settings/LIbraries, I just point
it to my cabal sandbox to fix this?)2014-11-13 17:33 GMT+01:00 Rik [email protected]:
Btw, can you start ghc-modi in root of your project?
—
Reply to this email directly or view it on GitHub
#2 (comment)
.
from intellij-haskell.
Is your project on github? So I can try to reproduce issue?
About the warning. Yes, add source code directory to Project Settings/Libraries. Tip: to see library source code in navigation window, put source codes of libraries inside project root.
from intellij-haskell.
I have ghc-mod and ghc-modi in ~/cabal/bin.
In Settings/Haskell I have set paths to ghc-mod and ghc-modi.
from intellij-haskell.
jip, it's on my github, it's a toy project
:[email protected]:KasperJanssens/talisman-haskell.git
to checkout some haskell stuff like lenses and so on, do a checkout of the
Board branch (that one has a cabal file :-)).
About adding source, it's for example complaining about the source to
system.random, how do I best go about putting the source of this library in
my project root? Next to that, IntelliJ only show my the possibility to add
jar files or stuff from maven in Project Settings/Libraries, expected or a
sign that the plugin didn't get correctly installed?
Concerning ghc-mod and ghc-modi, same thing for me. I now tried with the
latest version of ghc-mod as well, doesn't change anything.
Thanks for the responsiveness up until now already, I would really like to
use intellij for my haskell development and haven't managed to get one
haskell plugin working in a decent way, all my hope is on your plugin ;-).
2014-11-14 9:39 GMT+01:00 Rik [email protected]:
I have ghc-mod and ghc-modi in ~/cabal/bin.
In Settings/Haskell I have set paths to ghc-mod and ghc-modi.
—
Reply to this email directly or view it on GitHub
#2 (comment)
.
from intellij-haskell.
About source code. What I do is:
- Create in project root directory
lib
(or other name) - Inside
lib
do:cabal get random
- Go to Projects settings/Libraries.
- New project library
- Add
random
directory (as sources)
No problem :-)
from intellij-haskell.
Which version of IntelliJ are you using?
from intellij-haskell.
13.1.5. Wrong version? (that would be very very very silly of me).
2014-11-14 9:57 GMT+01:00 Rik [email protected]:
Which version of IntelliJ are you using?
—
Reply to this email directly or view it on GitHub
#2 (comment)
.
from intellij-haskell.
13.1.5 is okay. I asked question because 14 is just released.
from intellij-haskell.
I found the problem. Future time-out was too short. Because your project has more dependencies than projects I used, I did not notice this problem (ghc-modi is a slower in startup).
I will release new version today.
Thanks for reporting.
from intellij-haskell.
No probs, thanks for the help. I'll try to keep hammering on your plugin
from within my little pet project, you'll hear more from me most likely,
I'm extremely demanding on an IDE ;-P. Is there somewhere a list of
intellij-shortcuts that your plugin supports? I can see lots of stuff
that's supported, but I can't for example seem to find the inferred type
signature, doesn't show up when I hover, I don't seem to find a shortcut
that shows the inferred type, ... Being blind?
2014-11-14 11:10 GMT+01:00 Rik [email protected]:
I found the problem. Future time-out was too short. Because your project
has more dependencies than projects I used, I did not notice this problem
(ghc-modi is a slower in startup).I will release new version today.
Thanks for reporting.
—
Reply to this email directly or view it on GitHub
#2 (comment)
.
from intellij-haskell.
Alt+Equals shows type
In View
(of menu bar) you can see all actions (with short-cuts).
Btw, if you do not define type signature at top level, you can use Alt+Enter to put type signature above definition (derived by ghc-modi).
from intellij-haskell.
You also select expression and ask for type.
from intellij-haskell.
You can try version 0.4. It's already in Jetbrains repo and approved.
from intellij-haskell.
Fantastic, I'll try as soon as possible!
2014-11-14 11:48 GMT+01:00 Rik [email protected]:
You can try version 0.4. It's already in Jetbrains repo and approved.
—
Reply to this email directly or view it on GitHub
#2 (comment)
.
from intellij-haskell.
Works, thanks!
from intellij-haskell.
Rik,
I'm going to abuse this (closed) issue to ask a question. First of all, I'm very happy with the plugin, it works nice and fast, I guess I didn't discover everything yet, but navigating into the libraries and getting type info and such works really nicely. However, is there a way to run tests from within IntelliJ? I know this borders on cabal integration, but just asking. Also, is there a way to open modules by starting to type their name (like Ctrl-N for Java)? If these features aren't there, are they planned?
I'm open to start creating pull requests, but I haven't really made an intellij plugin yet (did some scala already, so the language should be okay), and I don't really know where to start in your source code if I would want to change functionality.
Kasper
from intellij-haskell.
No, at the moment I do not have plans to run tests in IntelliJ. I do not see a reason for that because if you use hspec (http://hspec.github.io/), you get already nice output in terminal.
To open a module, I use open file with (Ctrl+Shift+N). If you exclude directories like .cabal-sandbox,dist and so on, this way works fine for me because name of module is name of file. So no special feature planned for that.
You can checkout plugin code and try to understand it. If you have question let me know. Maybe we should use gtalk for helping you.
Take a look at:
http://confluence.jetbrains.com/display/IDEADEV/Developing+Custom+Language+Plugins+for+IntelliJ+IDEA
http://confluence.jetbrains.com/display/IntelliJIDEA/Custom+Language+Support
from intellij-haskell.
Ah, indeed, thanks for the tip about Ctrl Shift N, satisfies my needs indeed.
About the tests, you then use the terminal to talk to cabal/the compiled test binary and run tests like that, I take it? Okay, also possible indeed.
Oh, by the way, (I know I should stop hijacking this issue, it's the last thing), is there a place where you can see all the build issues? Crtl-F9 shows me build problems in the file I have open, but I don't seem to find a place where all the build issues are gathered.
from intellij-haskell.
No, because I do not build Haskell code inside IntelliJ. Could be a new feature :-) Normally I just do cabal build
in terminal.
from intellij-haskell.
Related Issues (20)
- Element: class intellij.haskell.HaskellFile #Haskell because: Monads.hs (invalid) is invalid
- Hoogle failed database generation causes documentation to be unavailable
- Refactor (rename) type name changes data constructor name, too
- Refactor-rename doesn't change occurences in other modules HOT 1
- "Add <someDataConstructor> to import list" doesn't work correctly
- HLint "Redundant <x>" suggestions often create garbled code HOT 2
- How do I set my project to use stack install on wsl2. Didn't find any doc about it.
- Creating a new project without Haskell installed fails HOT 3
- Plugin doesn't signal syntax errors HOT 1
- Why is plugin falling back on lts 18? HOT 2
- REPL does not start with IntelliJ IDEA 2022.2.1 HOT 2
- Error when creating new project
- Pipe symbol appears italic in guards
- Support post-qualified imports
- Inconsistent indentation after newline?
- New project error. HOT 1
- Intellij spellcheck issue
- How do I ignore my .ghci file to get rid of the error: [global-stack-repl] No result from REPL within 60 seconds. Command was: :load HOT 1
- Exception in plugin 1.0.0-beta88: "No display name specified in plugin descriptor XML file for configurable" HOT 3
- REPL couldn't be started for target
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from intellij-haskell.