My bash prompt is not working in `screen`How can avoid these spurious characters in my bash prompt?Why did a...
What is the parallel of Day of the Dead with Stranger things?
Found and corrected a mistake on someone's else paper -- praxis?
In Spider-Man: Far From Home, is this superhero name a reference to another comic book?
GDPR rights when subject dies; does family inherit subject rights?
How do we handle pauses in a dialogue?
The rigidity of the countable product of free groups
Why does every calorie tracking app give a different target calorie count for the same goals?
Yet another hash table in C
Is it okay to roll multiple attacks that all have advantage in one cluster?
Is there a strong legal guarantee that the U.S. can give to another country that it won't attack them?
What attributes and how big would a sea creature(s) need to be able to tow a ship?
Is a request to book a business flight ticket for a graduate student an unreasonable one?
Why do we need common sense in AI?
Received a dinner invitation through my employer's email, is it ok to attend?
How to compare the ls output of two folders to find a missing directory?
The joke office
Write a function
Credit score and financing new car
Is it OK to leave real names & info visible in business card portfolio?
When I press the space bar it deletes the letters in front of it
What is /bin/red
Under what hypotheses do all bounded sets have "area"?
How do you move up one folder in Finder?
Swapping "Good" and "Bad"
My bash prompt is not working in `screen`
How can avoid these spurious characters in my bash prompt?Why did a recent Ubuntu 14.04 update mess up my PS1 prompt?Bash - PS1 not Updating With Proper Hostname after Hostname Change in ScriptUpdate 'changing' variables every time PS1 is called, i.e. every new prompttmux not colorizing PS1 promptBash prompt (PS1) broken and spews errorsgnu screen stops working within applicationsColor codes in bash $PS1 not working in tmuxBash prompt configurationHow can I properly use an American flag emoji in my bash prompt?
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}
On RedHat, screen
resets my bash prompt. I set PS1=u@h:w
in ~/.bashrc
and ~/.bash_profile
.
I added shell -$SHELL
as well to ~/.screenrc
.
But, when I open a brand new terminal window, the prompt is correct, except in screen
.
In screen
I always get this prompt format: u@h>
How can I set the same prompt in screen
?
bash gnu-screen prompt
bumped to the homepage by Community♦ 2 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
On RedHat, screen
resets my bash prompt. I set PS1=u@h:w
in ~/.bashrc
and ~/.bash_profile
.
I added shell -$SHELL
as well to ~/.screenrc
.
But, when I open a brand new terminal window, the prompt is correct, except in screen
.
In screen
I always get this prompt format: u@h>
How can I set the same prompt in screen
?
bash gnu-screen prompt
bumped to the homepage by Community♦ 2 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
On RedHat, screen
resets my bash prompt. I set PS1=u@h:w
in ~/.bashrc
and ~/.bash_profile
.
I added shell -$SHELL
as well to ~/.screenrc
.
But, when I open a brand new terminal window, the prompt is correct, except in screen
.
In screen
I always get this prompt format: u@h>
How can I set the same prompt in screen
?
bash gnu-screen prompt
On RedHat, screen
resets my bash prompt. I set PS1=u@h:w
in ~/.bashrc
and ~/.bash_profile
.
I added shell -$SHELL
as well to ~/.screenrc
.
But, when I open a brand new terminal window, the prompt is correct, except in screen
.
In screen
I always get this prompt format: u@h>
How can I set the same prompt in screen
?
bash gnu-screen prompt
bash gnu-screen prompt
edited Sep 12 '13 at 8:27
jasonwryan
52.1k14 gold badges137 silver badges192 bronze badges
52.1k14 gold badges137 silver badges192 bronze badges
asked Sep 12 '13 at 8:21
user2013619user2013619
1001 gold badge1 silver badge5 bronze badges
1001 gold badge1 silver badge5 bronze badges
bumped to the homepage by Community♦ 2 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 2 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
I became so tired of the different startup files for shells that I do this:
- Create a file
~/.shrc
and put all my config in it (including the prompt setting) - In
~/.profile
,~/.bashrc
,~/.bash_profile
and whatever file the shell might read, add this line. ~/.shrc
(note the dot) - And finally, forget all about the little details that I never quite grasp
In your case, I suspect that Bash wants ~/.profile
(a wild guess, because as stated above I never got to fully understand those startup files), so adding that might make it work.
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
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%2f90350%2fmy-bash-prompt-is-not-working-in-screen%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
I became so tired of the different startup files for shells that I do this:
- Create a file
~/.shrc
and put all my config in it (including the prompt setting) - In
~/.profile
,~/.bashrc
,~/.bash_profile
and whatever file the shell might read, add this line. ~/.shrc
(note the dot) - And finally, forget all about the little details that I never quite grasp
In your case, I suspect that Bash wants ~/.profile
(a wild guess, because as stated above I never got to fully understand those startup files), so adding that might make it work.
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
add a comment |
I became so tired of the different startup files for shells that I do this:
- Create a file
~/.shrc
and put all my config in it (including the prompt setting) - In
~/.profile
,~/.bashrc
,~/.bash_profile
and whatever file the shell might read, add this line. ~/.shrc
(note the dot) - And finally, forget all about the little details that I never quite grasp
In your case, I suspect that Bash wants ~/.profile
(a wild guess, because as stated above I never got to fully understand those startup files), so adding that might make it work.
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
add a comment |
I became so tired of the different startup files for shells that I do this:
- Create a file
~/.shrc
and put all my config in it (including the prompt setting) - In
~/.profile
,~/.bashrc
,~/.bash_profile
and whatever file the shell might read, add this line. ~/.shrc
(note the dot) - And finally, forget all about the little details that I never quite grasp
In your case, I suspect that Bash wants ~/.profile
(a wild guess, because as stated above I never got to fully understand those startup files), so adding that might make it work.
I became so tired of the different startup files for shells that I do this:
- Create a file
~/.shrc
and put all my config in it (including the prompt setting) - In
~/.profile
,~/.bashrc
,~/.bash_profile
and whatever file the shell might read, add this line. ~/.shrc
(note the dot) - And finally, forget all about the little details that I never quite grasp
In your case, I suspect that Bash wants ~/.profile
(a wild guess, because as stated above I never got to fully understand those startup files), so adding that might make it work.
edited Apr 13 '17 at 12:36
Community♦
1
1
answered Sep 12 '13 at 10:15
phunehehephunehehe
12.5k18 gold badges84 silver badges141 bronze badges
12.5k18 gold badges84 silver badges141 bronze badges
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
add a comment |
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
Hello, I put "PS1=u@h:w" into: ~/.shrc, ~/.profile, but the screen still reset my prompt.
– user2013619
Sep 12 '13 at 14:13
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
@user2013619 try removing the PS1 settings from the other file if you're doing this.
– terdon♦
Sep 12 '13 at 14:36
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%2f90350%2fmy-bash-prompt-is-not-working-in-screen%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