tcoopman

tcoopman

I just came across: GitHub - a3lem/replink: A handy CLI for executing code in a REPL in a separate pane · GitHub and thought it would be cool if we could do the same with iex. I’m often copy pasting stuff, sending it directly from an editor would be awesome.

Showing Posts 1 to 4

tcoopman

tcoopman OP

Ah, I just noticed that this code doesn’t rely on the python cli, but rather on tmux: replink/replink/core.py at 4abd8dbdaf29b916649fcba10296977a5b9ef10d · a3lem/replink · GitHub

So yes, this should be possible with IEx as well if you’re using tmux for example.

sodapopcan

sodapopcan

I made something like this though only works in Vim (but not nvim). You can highlight text and send it to a :term and it gets updated as you update the code in the buffer. It’s pretty hacky—it just copies the code from the buffer to a tempfile then import_filess it in the term window (adding that line to your IEx history). In any event, it’s possible :smiley:

I would love to be able to connect to a running REPL a-la clojure. It would allow for more flexibility than LSP (though of course back to editor-specific implementations). There’s been discussion about it around here but I don’t think there is much movement around it (I was feeling motivated but then moved on).

EDIT: I forgot I made a screencast about it—it’s my first and only screencast so be nice (lol).

victor23k

victor23k

That’s cool! I made a Neovim plugin that does something similar - it sends the character to the term and adds a line break at the end to execute the command.

Do you use your Vim plugin often? I also have the dream for better interaction with IEx but unfortunately I don’t have much time to build something right now and I end up typing directly in IEx more than I would like to.

sodapopcan

sodapopcan

I ended up not using it too much since the auto-update for mix projects arrived weeks later. I also use tests a lot to run random stuff. It was largely more of an experiment and just showed in into my plugin :slight_smile: But ya, an actual connected iex is the dream.

— All posts loaded —

Where Next? Top

Trending in Questions Top

RSP87
I’m working on a project that simulates the bumbl example in the programming phoenix book. It acts almost like an email client. We have a...
New
nseaSeb
Hello, I know there is an approach for handling lists that allows for optimized traversal, but I can’t recall the specific method (somet...
New
brecabral
Documentation While reading the Scoped Routes section, I noticed that the documentation currently refers to a problem without explainin...
New
RemyXRenard
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
velrest
So my question is quite simple and i have found no conclusive answer on forum, google or AI. Should we use :erlang.float for Integer to ...
New
samoloth
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
FlyingNoodle
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New

Other Trending Topics Top

JesseHerrick
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
mudasobwa
I am happy to introduce the very α version of the new programming language compiled to BEAM. Welcome Cure. It has literally three kille...
New
marciok
Hi there! We created Gust: A task orchestrator inspired by Airflow. For those who have never heard about Aiflow, it’s a Python-based wor...
New
mhanberg
Hi everyone! The first release candidate for the Expert language server project is now available! We’ve published a press release detai...
New
jimsynz
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Dmk
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New

We're in Beta

About us Mission Statement

Options

Thread Display Mode




Thread Preview

Skip Thread Previews