understand the output of stty -a and change ctrl backspace to just backspace
I am working in bash shell on a Solaris environment and whenever I type "backspace" it clears out the entire line.
Do you have any suggestions for me to change the backspace clearing entire line to just a character which is the expected behavior of it?
Hhow do I interpret the output of stty -a command in my local cygwin environment:
$ stty -a <br/>
speed 38400 baud; rows 34; columns 125; line = 0;
intr = ^C; quit = ^; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; swtch = ^Z; start = ^Q; stop = ^S;
susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc ixany imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -tostop echoctl echoke
bash cygwin stty
add a comment |
I am working in bash shell on a Solaris environment and whenever I type "backspace" it clears out the entire line.
Do you have any suggestions for me to change the backspace clearing entire line to just a character which is the expected behavior of it?
Hhow do I interpret the output of stty -a command in my local cygwin environment:
$ stty -a <br/>
speed 38400 baud; rows 34; columns 125; line = 0;
intr = ^C; quit = ^; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; swtch = ^Z; start = ^Q; stop = ^S;
susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc ixany imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -tostop echoctl echoke
bash cygwin stty
add a comment |
I am working in bash shell on a Solaris environment and whenever I type "backspace" it clears out the entire line.
Do you have any suggestions for me to change the backspace clearing entire line to just a character which is the expected behavior of it?
Hhow do I interpret the output of stty -a command in my local cygwin environment:
$ stty -a <br/>
speed 38400 baud; rows 34; columns 125; line = 0;
intr = ^C; quit = ^; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; swtch = ^Z; start = ^Q; stop = ^S;
susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc ixany imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -tostop echoctl echoke
bash cygwin stty
I am working in bash shell on a Solaris environment and whenever I type "backspace" it clears out the entire line.
Do you have any suggestions for me to change the backspace clearing entire line to just a character which is the expected behavior of it?
Hhow do I interpret the output of stty -a command in my local cygwin environment:
$ stty -a <br/>
speed 38400 baud; rows 34; columns 125; line = 0;
intr = ^C; quit = ^; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>; swtch = ^Z; start = ^Q; stop = ^S;
susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff -iuclc ixany imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -tostop echoctl echoke
bash cygwin stty
bash cygwin stty
edited 8 hours ago
Rui F Ribeiro
41.3k1481140
41.3k1481140
asked Apr 18 '14 at 8:32
AvinashAvinash
1181412
1181412
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
From the wording of your question, I'm assuming that you're using cygwin to access a Solaris machine.
stty -a displays all the current settings for the terminal. I won't go through each one. But you can read up on what each one does on the man pages.
But of particular note to your problem is erase = ^?;. ^? is the ASCII Control Character for DEL (delete). What you want is the control character for BS (backspace).
From the command line you can type the following:
stty erase ^H
But note that the ^H is a control character and not ^H. So I believe the way that you would type this is as follows:
Ctrl+vbackspace
And that should result in ^H being printed to the screen.
That should change the behavior of backspace to what you want. But it would only last for the current session.
According to this Oracle blog, you can permanently change the configuration by opening /kernel/drv/options.conf and looking for the following line:
ttymodes="2502:1805:bd:8a3b:3:1c:7f:15:4:0:0:0:11:13:1a:19:12:f:17:16";
Change the 7f to 8 to permanently remap backspace from DEL to BS. This will require a reboot to take effect.
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f125340%2funderstand-the-output-of-stty-a-and-change-ctrl-backspace-to-just-backspace%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
From the wording of your question, I'm assuming that you're using cygwin to access a Solaris machine.
stty -a displays all the current settings for the terminal. I won't go through each one. But you can read up on what each one does on the man pages.
But of particular note to your problem is erase = ^?;. ^? is the ASCII Control Character for DEL (delete). What you want is the control character for BS (backspace).
From the command line you can type the following:
stty erase ^H
But note that the ^H is a control character and not ^H. So I believe the way that you would type this is as follows:
Ctrl+vbackspace
And that should result in ^H being printed to the screen.
That should change the behavior of backspace to what you want. But it would only last for the current session.
According to this Oracle blog, you can permanently change the configuration by opening /kernel/drv/options.conf and looking for the following line:
ttymodes="2502:1805:bd:8a3b:3:1c:7f:15:4:0:0:0:11:13:1a:19:12:f:17:16";
Change the 7f to 8 to permanently remap backspace from DEL to BS. This will require a reboot to take effect.
add a comment |
From the wording of your question, I'm assuming that you're using cygwin to access a Solaris machine.
stty -a displays all the current settings for the terminal. I won't go through each one. But you can read up on what each one does on the man pages.
But of particular note to your problem is erase = ^?;. ^? is the ASCII Control Character for DEL (delete). What you want is the control character for BS (backspace).
From the command line you can type the following:
stty erase ^H
But note that the ^H is a control character and not ^H. So I believe the way that you would type this is as follows:
Ctrl+vbackspace
And that should result in ^H being printed to the screen.
That should change the behavior of backspace to what you want. But it would only last for the current session.
According to this Oracle blog, you can permanently change the configuration by opening /kernel/drv/options.conf and looking for the following line:
ttymodes="2502:1805:bd:8a3b:3:1c:7f:15:4:0:0:0:11:13:1a:19:12:f:17:16";
Change the 7f to 8 to permanently remap backspace from DEL to BS. This will require a reboot to take effect.
add a comment |
From the wording of your question, I'm assuming that you're using cygwin to access a Solaris machine.
stty -a displays all the current settings for the terminal. I won't go through each one. But you can read up on what each one does on the man pages.
But of particular note to your problem is erase = ^?;. ^? is the ASCII Control Character for DEL (delete). What you want is the control character for BS (backspace).
From the command line you can type the following:
stty erase ^H
But note that the ^H is a control character and not ^H. So I believe the way that you would type this is as follows:
Ctrl+vbackspace
And that should result in ^H being printed to the screen.
That should change the behavior of backspace to what you want. But it would only last for the current session.
According to this Oracle blog, you can permanently change the configuration by opening /kernel/drv/options.conf and looking for the following line:
ttymodes="2502:1805:bd:8a3b:3:1c:7f:15:4:0:0:0:11:13:1a:19:12:f:17:16";
Change the 7f to 8 to permanently remap backspace from DEL to BS. This will require a reboot to take effect.
From the wording of your question, I'm assuming that you're using cygwin to access a Solaris machine.
stty -a displays all the current settings for the terminal. I won't go through each one. But you can read up on what each one does on the man pages.
But of particular note to your problem is erase = ^?;. ^? is the ASCII Control Character for DEL (delete). What you want is the control character for BS (backspace).
From the command line you can type the following:
stty erase ^H
But note that the ^H is a control character and not ^H. So I believe the way that you would type this is as follows:
Ctrl+vbackspace
And that should result in ^H being printed to the screen.
That should change the behavior of backspace to what you want. But it would only last for the current session.
According to this Oracle blog, you can permanently change the configuration by opening /kernel/drv/options.conf and looking for the following line:
ttymodes="2502:1805:bd:8a3b:3:1c:7f:15:4:0:0:0:11:13:1a:19:12:f:17:16";
Change the 7f to 8 to permanently remap backspace from DEL to BS. This will require a reboot to take effect.
answered Apr 18 '14 at 13:39
embedded.kyleembedded.kyle
2321413
2321413
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f125340%2funderstand-the-output-of-stty-a-and-change-ctrl-backspace-to-just-backspace%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown