IVR

IVR

Elixir IDEs and developer tools

Hi all, I’m new here and I’d like to apologise if this question isn’t exactly original, however, I haven’t found a satisfactory answer to my questions, so I’m posting this here anyway.

I’m getting started with Elixir and I haven’t quite figured out what IDE to use with it. I’d like to understand what tools are other Elixir developers using and I’d also like to highlight problems that I ran into while setting up my development environment. We might not be able to resolve all of them, but perhaps we might be able to resolve at least one.

I come from an IntelliJ background and here is the summary of what I’ve tried and where I’ve experienced problems:

  • IntelliJ with the Elixir plugin: as I mentioned above, IntelliJ would be my preferred IDE, however even after installing the Elixir plugin and setting both Elixir and Erlang SDKs, IntelliJ isn’t complaining about anything but auto-completion and definition lookups don’t seem to work. I’ve found a number of related issues, like this one, but haven’t been able to resolve this problem.
  • RubyMine with the Elixir plugin: I thought this should be very similar to IntelliJ, but I ran into a different problem when using RubyMine, I got an error “Elixir Module SDK is not defined” and even though there is a button next to it that says “Setup Elixir Module SDK”, nothing happens when I click it. If I go into Preferences → Languages & Frameworks → Elixir → SDKs and if I try to set an Elixir SDK, I get an error “Cannot save settings: please specify a different SDK name”. At least here I had an error to work with, but after about 20 minutes I’ve given up and decided to try option 3 (below)
  • VS Code with the Elixir extension: This option works the best and I’m actually beginning to like VS Code. My biggest and so far the only problem is refactoring. In IntelliJ (or related tools) it’s as easy as Ctrl+T and all uses and definitions of the thing you are trying to refactor are updated, whereas in VS Code this seems like a major hassle. I’ve found ways to change a definition within a file but not throughout the project. If anyone has any suggestions here, then please let me know

Thank you all in advance for reading!

Marked As Solved

drl123

drl123

I noticed you were using the Homebrew installed packages in the screenshot, so I tried on my daughter’s iMac which had nothing installed previously and is running Catalina. Did a fresh install of Homebrew, Erlang and Elixir and the latest version of RM. I had zero issues. Did you happen to ever set up Elixir via any other method (like ASDF, etc.)? Perhaps the Homebrew one is not active?

Deleting the .idea folder may help. I’ve had issues in the past trying to share an Elixir project with IntelliJ CE and RM. The .iml files are slightly different and it would screw up the second IDE you tried.

I did play around with VSCode today a little. Takes a lot of set up/plugins to get what comes natively with RM and IntelliJ Elixir…still missing a few things like the nice test runner, but it works. Im still partial to the JetBrains IDE’s though, maybe just familiarity.

If you are still interested in getting it going, file an issue with @KronicDeth on the plugin GitHub. He’s been super helpful when I’ve been stuck or had issues.

Also Liked

mpalmer

mpalmer

I’m pretty new to elixir as well, with a similar background as you (IntelliJ for most projects). I found that VSCode was (as you said) surprisingly nice. Refactoring is definitely a challenge, though I can’t say I have found it too much of an issue.

I work in a windows environment, though I prefer linux, and have found that WSL2 with alpine does everything I need. VSCode connects to it directly, and iex is much more pleasant (autocomplete works, pretty colors).

For me the biggest shift, coming from intellij and java and huge unwieldy codebases, is the simplicity. Building systems in Elixir (and they certainly feel and act like systems rather than plain old applications), somehow manages to organize complexity in a clean and manageable way. Having an IDE for Java is almost always necessary because there are often so many pieces flying around that it helps keep them all straight. With Elixir, it all just doesn’t seem so messy.

I hope this helps - your background definitely sounds a lot like mine, so I can understand the initial struggle to get comfortable with Elixir. But certainly it is worth every discomfort and mind-shift.

axelson

axelson

Scenic Core Team

Personally, I use Doom Emacs with ElixirLS for development. But my general sense is that the majority of Elixir developers now use VSCode (and VSCode is significantly easier to get started with than Emacs). So VSCode is my general recommendation (with ElixirLS and not vscode-elixir since it is not maintained).

With Elixir, it is generally reasonable to use generic project-wide (and sometimes single-file) search and replace to refactor variable names. Or at least reasonable enough that no-one’s created tooling to do context-aware refactoring. But if someone were to implement refactoring in ElixirLS that would be much appreciated and could then be used across a large variety of editors.

NeutronStein

NeutronStein

You can try Onivim2 which gives you the best of vim and vscode. It is very fast, nice and neat. :wink:

Where Next?

Popular in Questions Top

chokchit
** (DBConnection.ConnectionError) connection not available and request was dropped from queue after 2733ms. You can configure how long re...
New
beno
I will often find my self writing things similar to: case some_value do nil -> something() "" -> something() _ -> somethi...
New
jerry
Good day to you all. I have been struggling to get a query involving like and ilike to work. Can anyone assist me on this, please? pro...
New
SoCreat
i’m a new one to elixir which editor can i use vs code? or atom? Thanks! :smiley:
New
JDanielMartinez
Hi! May someone helps me, please! I have two apps into an umbrella project: the first one is Database, which manages queries, and the se...
New
dblack
I’ve got an issue with an app and I’ve no idea of how to troubleshoot it. I’m hoping someone here might have seen something similar. I p...
New
PeterCarter
There are pre-rolled solutions for other frameworks that do work. However, Phoenix does not seem to have these. Have people had good expe...
New
JorisKok
I have a server on AWS, and was running a load test using artillery. When looking at the Phoenix dashboard I see the Ports going to 100% ...
New
minhajuddin
I have seen a lot of code which picks the first element from a list using Enum.at(0) instead of List.first. Is there a reason why people ...
New
lanycrost
Hi everyone! I need implement if…else if…else condition from my elixir code, and anymore of this control flow structures not work proper...
New

Other popular topics Top

Emily
I have VueJS GUIs with the project generated using Webpack. I have Elixir modules that will need to be used by the VueJS GUIs. I forese...
New
lessless
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
johnnyicon
Hi all, I’ve just started learning Elixir and Phoenix Framework, so please pardon my n00bness at this stage. I’m trying to use Postgres...
New
fireproofsocks
Forgive me if this is obvious, but how does one delete a database record WITHOUT selecting it first? Ecto.Repo — Ecto v3.14.0 has exampl...
New
RisingFromAshes
I’ve read in another post that it may be possible with a router helper - but I couldn’t find an appropriate one, and tbh, I’m still just ...
New
dblack
I’ve got an issue with an app and I’ve no idea of how to troubleshoot it. I’m hoping someone here might have seen something similar. I p...
New
hariharasudhan94
I would like to know what is the best IDE for elixir development?
New
dogweather
I wrote this comment on r/haskell, and it’s not popular there. :wink: But I think I’m on to something… Haskell reminds me of Java, and e...
New
jononomo
For some reason my phoenix channels are working for me in my local dev environment, but as soon as I deploy via Docker, I get a 403 error...
New
JorisKok
I have a server on AWS, and was running a load test using artillery. When looking at the Phoenix dashboard I see the Ports going to 100% ...
New

We're in Beta

About us Mission Statement