Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How Would You load-file With SBCL? #200

Open
FOSSilizedDaemon opened this issue Jul 23, 2021 · 5 comments
Open

How Would You load-file With SBCL? #200

FOSSilizedDaemon opened this issue Jul 23, 2021 · 5 comments

Comments

@FOSSilizedDaemon
Copy link

Hello,

I don't know where best to put this, but figured others would have the same question. I read your documentation on using vimux to replicate SLIME behavior and for the most part everything works fine, but there is one thing I can't figure out how to do with vimux that SLIME does do. How do I load the current file into a consistent sbcl/REPL session with vimux?

@m42e
Copy link
Contributor

m42e commented Aug 11, 2021

I'm not familiar with slime, so would you mind, explaining what your workflow would look like and what you expect to happen?

@FOSSilizedDaemon
Copy link
Author

@m42e To explain this I will give an example work session, just to make everything easier. You boot up your computer, and launch a terminal, get tmux ready and the whole 9 yards.

You open your lisp file in vim/nvim, and then you press your keybinding for vimux to get a split. When this split is open, sbcl is launched and the current file being edited is loaded into sbcl. Then, you can go around make some new edits and so on, then you hit the binding again and instead of quitting and relaunching sbcl to load the file you would just reload that file inside the already running sbcl session.

1 similar comment
@FOSSilizedDaemon
Copy link
Author

@m42e To explain this I will give an example work session, just to make everything easier. You boot up your computer, and launch a terminal, get tmux ready and the whole 9 yards.

You open your lisp file in vim/nvim, and then you press your keybinding for vimux to get a split. When this split is open, sbcl is launched and the current file being edited is loaded into sbcl. Then, you can go around make some new edits and so on, then you hit the binding again and instead of quitting and relaunching sbcl to load the file you would just reload that file inside the already running sbcl session.

@m42e
Copy link
Contributor

m42e commented Aug 11, 2021

Ok, and does sbcl support this? Is there a specific command one could run? What would you type there to perform the reload?

@alerque
Copy link
Member

alerque commented Aug 12, 2021

I know several REPLs that support listening to a named pipe for more code to load into the live environment, and others that you can just dump more code onto STDIN. However each one is just a bit different so I don't expect there is a generalized solution for this.

Vimux supports plugins. I suspect this is a good use case for one. A SBCL specific vimux plugin could take care of adding a command that wrote or piped the current buffer wherever it needed to go to inject it into a running REPL.

If there is anything we can do on this end to make support easier or more robust we're all ears, but overall rather than supporting ways to pass data to every different thing that could be running in a terminal I think supporting specific dev workflows like this is probably best organized in plugin form.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants