Switching back and forth quickly between matlab-shell and source buffer + Ctrl+Z on matlab repl completely freezes it
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 38/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- emacs, emacs-lisp
- Domain
- developer-experience, tooling
Research direction
Start at the matlab-shell entry point and trace how focus switches between MATLAB source and REPL buffers, including what Ctrl+Z does in the REPL. Define done as providing a reliable way to switch back to the prior source buffer and ensuring Ctrl+Z does not leave the MATLAB session apparently frozen.
Written by the indexing model from the issue text.
Description
I've started using julia quite a lot recently using the package julia-snail on emacs. If the function (julia-snail) is called from a source code buffer, focus switches to the julia REPL buffer, and if it was called from the REPL buffer, focus switches to the source. It remembers the last source buffer from which the julia-snail function is called, making this super neat to work with.
By default I have this function mapped to Ctrl+Z so I'm hitting ctrl+z all the time, especially when I have 4 windows with different buffers open at the same time with only one being the repl.
In matlab mode, we have the function matlab-shell so I can go from source to matlab repl. But no function like this seems to exist for going back.
I have added personal frustration since I have matlab-shell bound to Ctrl+Z. And hitting Ctrl+Z in the matlab-repl freezes up the repl completely.
This is my second query in this sub issue The behavior of Ctrl+Z on the matlab-shell is confusing. Once I hit Ctrl+Z on the matlab-shell, I'm unsure just what I need to do to resume the session. So far I've been killing matlab-shell completely and continuing.
Here's the julia-snail code just in case:
(defun julia-snail ()
"Start a Julia REPL and connect to it, or switch if one already exists.
The following buffer-local variables control it:
- `julia-snail-repl-buffer' (default: *julia*)
- `julia-snail-port' (default: 10011)
To create multiple REPLs, give these variables distinct values (e.g.:
*julia my-project-1* and 10012)."
(interactive)
(let ((source-buf (current-buffer))
(repl-buf (get-buffer julia-snail-repl-buffer)))
(if repl-buf
;; Julia session exists
(progn
(with-current-buffer repl-buf
(setq julia-snail--repl-go-back-target source-buf))
(pop-to-buffer repl-buf))
;; run a new Julia REPL in a terminal and load the Snail server file
(julia-snail--start source-buf))))
- Dominant language
- Emacs Lisp
- Stars
- 27
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from mathworks/Emacs-MATLAB-Mode
-
Difficulty 5/5 Over a week Newbie friendliness 15/100
-
Difficulty 3/5 1-2 days Newbie friendliness 28/100
mathworks/Emacs-MATLAB-Mode#59 · 3 comments · 1 reaction ·
-
Difficulty 5/5 Over a week Newbie friendliness 25/100
mathworks/Emacs-MATLAB-Mode#50 · 1 comment ·
-
ELPA links to doc and examples from README.org don't workMay be free again @ouboub claimed this 505 days ago, and no pull request is open. Open
mathworks/Emacs-MATLAB-Mode#47 · 1 assignee ·
-
Add guide for working with MATLAB and creating scientific papers in EmacsMay be free again @JohnC32 claimed this 505 days ago, and no pull request is open. Opendocumentation
mathworks/Emacs-MATLAB-Mode#46 · 1 assignee ·
All issues in mathworks/Emacs-MATLAB-Mode
Similar issues
-
automation models
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 1 day
-
install.ps1: Windows PowerShell 5.1 aborts after a successful cosign verification (NativeCommandError on 'Verified OK')Possibly taken @sly321-pixel claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 83/100
Kotlin/kotlin-lsp#288 ·
-
tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
spec-kitty/spec-kitty#6111 ·
Maintainers usually reply within 1 day
-
documentation P2 size-s
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
gracecraft-software/lupin#145 ·
Maintainers usually reply within 1 day