[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/swift-mode 0daff60 463/496: Fix unreadable characters appe
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/swift-mode 0daff60 463/496: Fix unreadable characters appearing in repl prompt |
Date: |
Sun, 29 Aug 2021 11:34:28 -0400 (EDT) |
branch: elpa/swift-mode
commit 0daff60105eee0f936976543e0e0e65c88627ab4
Author: Jaeyoon Jeong <dalgong@users.noreply.github.com>
Commit: taku0 <taku0@users.noreply.github.com>
Fix unreadable characters appearing in repl prompt
This seems a better fix for swift-emacs/swift-mode#132; The original
solution didn't work for me.
---
swift-mode-repl.el | 28 ++++++++++++++++------------
1 file changed, 16 insertions(+), 12 deletions(-)
diff --git a/swift-mode-repl.el b/swift-mode-repl.el
index db82504..e33af51 100644
--- a/swift-mode-repl.el
+++ b/swift-mode-repl.el
@@ -176,21 +176,25 @@ Runs the hook `swift-repl-mode-hook' \(after the
`comint-mode-hook' is run).
(cmd-string (swift-mode:command-list-to-string cmd))
(cmd-list (swift-mode:command-string-to-list cmd))
(buffer-name (concat "*Swift REPL [" cmd-string "]*"))
- (buffer (get-buffer-create buffer-name)))
- (unless dont-switch
- (pop-to-buffer buffer))
- (with-current-buffer buffer
- (unless (comint-check-proc buffer-name)
- (save-excursion
- (apply 'make-comint-in-buffer
- cmd-string buffer (car cmd-list) nil (cdr cmd-list))
- (swift-repl-mode)))
- (setq-local swift-mode:repl-buffer buffer-name))
+ (buffer (get-buffer-create buffer-name))
+ old-size)
(with-current-buffer original-buffer
- (setq-local swift-mode:repl-buffer buffer-name)
+ (setq-local swift-mode:repl-buffer buffer)
(unless keep-default
(setq-local swift-mode:repl-executable cmd)
- (setq-default swift-mode:repl-buffer swift-mode:repl-buffer)))))
+ (setq-default swift-mode:repl-buffer swift-mode:repl-buffer)))
+ (with-current-buffer buffer
+ (setq old-size (buffer-size))
+ (swift-repl-mode)
+ (setq-local swift-mode:repl-buffer buffer))
+ (unless (comint-check-proc buffer)
+ (apply 'make-comint-in-buffer
+ cmd-string buffer (car cmd-list) nil (cdr cmd-list))
+ (with-current-buffer buffer
+ (while (= old-size (buffer-size))
+ (sleep-for .1))))
+ (unless dont-switch
+ (pop-to-buffer buffer))))
;;;###autoload
(defalias 'run-swift 'swift-mode:run-repl)
- [nongnu] elpa/swift-mode d59cae7 355/496: Fix indentation of string interpolations, (continued)
- [nongnu] elpa/swift-mode d59cae7 355/496: Fix indentation of string interpolations, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 2aeef85 425/496: Update copyright notice, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 490ab34 051/496: Simplify indentation command, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 66bfbc5 056/496: Add indentation tests, add makefile runner task, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode ead0ae5 055/496: Fix spelling error in readme, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 049c6d6 439/496: Use `assoc-default`, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode ba4d981 473/496: Use seq-contains-p if available, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 86f8f62 447/496: Bump version to 8.0.1, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 90686cb 450/496: Add `some` keyword of Swift 5.1, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode acfc7fd 452/496: Fix comments, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 0daff60 463/496: Fix unreadable characters appearing in repl prompt,
ELPA Syncer <=
- [nongnu] elpa/swift-mode 5597eaf 467/496: Avoid max-lisp-eval-depth in font-lock-match-expr, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 8f1a697 483/496: Fix documentations, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode cb6186e 474/496: Add support for font-lock-negation-char-face, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode b6d0351 338/496: Fix indentation of switch, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 07939df 413/496: Bump version to 7.0.0, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 55ce4e5 416/496: Fix command name, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode fa4f491 433/496: Add Emacs 25.3 and 26.1 to CI, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 3b6bdad 443/496: Bump version to 8.0.0, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode be8d770 446/496: Fix indentation after `class' modifier, ELPA Syncer, 2021/08/29
- [nongnu] elpa/swift-mode 3d1cfcc 047/496: Clarify manual installation, ELPA Syncer, 2021/08/29