Comments (12)
hmm, I think this sounds familiar as documented Emacs behaviour due to the load order of .dir-locals.el
. The relevant part of my init.el
points at https://emacs.stackexchange.com/questions/7743 as an example, also see the docs of hack-local-variables-hook
.
from dante.
@michalrus no problem, I hope to one day be a) a haskell developer b) using this mode.
from dante.
btw, it sounds hacky, but I'm actually fine with the Emacs approach. I don't believe anybody has solved the generic problem of load order for any customisable system automatically. Even my xbox computer games have a "load order" for mods, which is the same problem, in a different guise. When customising a core tool, we have to open up the hood sometimes.
FYI additional thing... when I load whitespace-mode
and want to use local variables I use this alternative function instead of the default hook loader.
(defun whitespace-mode-with-local-variables ()
"A variant of `whitespace-mode' that can see local variables."
(add-hook 'hack-local-variables-hook 'whitespace-mode nil t))
Which is the escape hatch.
from dante.
the other thing dante
could do would be to make dante-target
buffer local by default, e.g. https://stackoverflow.com/questions/21917049 i.e. call (make-variable-buffer-local 'dante-target)
immediately after defining it.
(users must then use setq-default
instead of setq
) and also add to the safe-local-variable
list. Example from another project: Wilfred/ag.el#145
I recommend that anything project-specific be made buffer local in a similar fashion.
from dante.
Just learned that the order of the hooks matters. The issue is only there if the flycheck-mode hook comes after the dante-mode hook.
from dante.
Emacs is depressing. #ihatemyeditor
Thank you very much, tho.
from dante.
Did you get to the bottom of why the flycheck-mode hook was needed?
from dante.
No, right now I have an “if it works I freakin’ don’t care” relation w/ Emacs. :throw_up:
But I think I remember a similar problem with Scala and its ENSIME. Maybe let’s… /cc @fommil?
from dante.
@joehealy I actually found out that the hook wasn't really necessary for me in the first place. 😕
from dante.
@fommil, thank you for all the details! =)
from dante.
I very much recommend the switch. It’s been an amazing experience so far for me. ^.^
from dante.
it's my employers who need to be convinced...
from dante.
Related Issues (20)
- Crash upon opening .hs file HOT 7
- Donations/sponsorships? HOT 2
- Jump to definition and Info unreliable. Configuration of test targets hard to get right HOT 13
- Error while checking syntax automatically: (error "Buffer *dante:<name>::<path>/* has no process") HOT 1
- Tooltip errors don't display hole fits every time HOT 1
- hlint-enabling snippet adds haskell-hlint many times
- Dante forgets directory variables (dante-methods) from time to time HOT 1
- Problem with global-flycheck-mode enabled HOT 1
- dir-local dante-target HOT 6
- Bad formating if no newline present
- Unable to get dante working with SimulaVR HOT 2
- How is this related to the haskell-language-server? HOT 2
- Setting up Dante Targets for enabling jump to definition and repl HOT 1
- Using Dante with stack script HOT 9
- Support for Emacs 27 dropped in 6d212f3 HOT 5
- Warnings and errors disappear after asking flycheck to reload unchanged buffer. HOT 1
- Complains about no loading method applies, even if all variables are set.
- dante doesn't install with Aquamacs
- Corfu integration
- "These modules are needed for compilation but not listed in your .cabal" error HOT 2
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 dante.