mirror of
git://git.sv.gnu.org/emacs.git
synced 2025-12-06 14:30:50 -08:00
Disable echo back instead of setting tty to raw in Inferior Python
* lisp/progmodes/python.el (python-shell-setup-code): Change the
Python setup code. (Bug#76943)
(cherry picked from commit 4c5c20ddc2)
This commit is contained in:
parent
01d4eb3dd4
commit
4dcd66abd5
1 changed files with 4 additions and 2 deletions
|
|
@ -3528,11 +3528,13 @@ eventually provide a shell."
|
||||||
(defconst python-shell-setup-code
|
(defconst python-shell-setup-code
|
||||||
"\
|
"\
|
||||||
try:
|
try:
|
||||||
import tty
|
import termios
|
||||||
except ImportError:
|
except ImportError:
|
||||||
pass
|
pass
|
||||||
else:
|
else:
|
||||||
tty.setraw(0)"
|
attr = termios.tcgetattr(0)
|
||||||
|
attr[3] &= ~termios.ECHO
|
||||||
|
termios.tcsetattr(0, termios.TCSADRAIN, attr)"
|
||||||
"Code used to setup the inferior Python processes.")
|
"Code used to setup the inferior Python processes.")
|
||||||
|
|
||||||
(defconst python-shell-eval-setup-code
|
(defconst python-shell-eval-setup-code
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue