This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Konsole and login shell

Tags: None
(comma "," separated)
kde-slacker
Registered Member
Posts
4
Karma
0

Konsole and login shell

Fri Aug 20, 2021 1:58 am
I am running KDE Plasma 5.22.4, Frameworks 5.85, and Konsole 21.08. Going into the profile settings and editing the command /bin/bash , just by adding -l to the end so it reads
Code: Select all
/bin/bash -l


I apply the changes and restart konsole, but it still does not open as a login shell and I just get bash5.15$ for the prompt instead of user@pcname:~$, I even tried editing the konsolerc file in ~/config , but still no luck. I have seen this behavior since the last iteration of KDE Plasma Frameworks, and I was hoping this release would resolve it but it doesn't. Is there any other way to force konsole to open / show the prompt as login shell ?
koffeinfriedhof
Registered Member
Posts
608
Karma
4
OS

Re: Konsole and login shell

Fri Aug 20, 2021 9:59 am
Hi!

For me (on arch) it still works as expected. What OS do you use? Is /bin/bash the bash or a symlink to busybox? Did you configure your /etc/profile, .bash_profile or similar?
kde-slacker
Registered Member
Posts
4
Karma
0

Re: Konsole and login shell

Sat Aug 21, 2021 7:09 pm
koffeinfriedhof wrote:Hi!

For me (on arch) it still works as expected. What OS do you use? Is /bin/bash the bash or a symlink to busybox? Did you configure your /etc/profile, .bash_profile or similar?


Hello I am running Slackware Linux --Current RC1 , however even before it was RC status this was an issue. Although Slackware FINALLY adopted Plasma5 , initially I didn't have this issue, I do not recall what version that this issue started happening on , but I still cannot get a login shell displayed instead of just bash5.x , I am checking with the distro maintainer, but no word yet to see if it is indeed an issue with Slackware, it could be - but I for now think it might be a weird bug. Is there at least a work around?
koffeinfriedhof
Registered Member
Posts
608
Karma
4
OS

Re: Konsole and login shell

Sun Aug 22, 2021 8:37 am
Without knowing your login shell, I have no idea how to workaround it. So again: is [/usr]/bin/bash a symlink or an installed version? What is the login shell of your user? What about the basic configuration files of the shells, like profile, bashrc, …?
kde-slacker
Registered Member
Posts
4
Karma
0

Re: Konsole and login shell

Mon Aug 23, 2021 9:57 pm
koffeinfriedhof wrote:Without knowing your login shell, I have no idea how to workaround it. So again: is [/usr]/bin/bash a symlink or an installed version? What is the login shell of your user? What about the basic configuration files of the shells, like profile, bashrc, …?


.profile and .bashrc are not in ~ , Slackware is like Debian now where those files are no longer in the ~ directory of the user. I have checked, and bash is a symlink as you theorized, pointing to /bin/bash
kde-slacker
Registered Member
Posts
4
Karma
0

Re: Konsole and login shell

Tue Aug 24, 2021 3:41 am
I got it to work, I went into profile itself and created another profile, and set it to default and it works. Only dumb thing is I still have the initial profile there (readonly) and I can't get rid of it, so I have two entries - but now I got Konsole the way I want it at least - opening up as a login shell with my fortunes.
koffeinfriedhof
Registered Member
Posts
608
Karma
4
OS

Re: Konsole and login shell

Wed Aug 25, 2021 9:57 am
kde-slacker wrote:.profile and .bashrc are not in ~ , Slackware is like Debian now where those files are no longer in the ~ directory of the user. I have checked, and bash is a symlink as you theorized, pointing to /bin/bash

Does /bin/bash is a symlink itself or a file?
You do not need a ~/{.profile,.bashrc} as the system wide configuration in /etc/ will set it up anyway.

Your loginshell is the last entry in every line you find in /etc/passwd
Code: Select all
awk -F: '{ print $1,"→", $NF}' /etc/passwd


You can change this with `chsh` command. Konsole should use this as a default, als Konsole itself is a graphical terminal and should/does not allow the usage as a login terminal. That is why you always have to manually enter `bash --login`. But your environment should be loaded by Konsole itself. Try it with a simple ~/.bashrc`:
Code: Select all
PS1="\u at \h in \w › "
which will change your prompt to 'user at host in path › '


Bookmarks



Who is online

Registered users: bartoloni, Bing [Bot], Google [Bot], Sogou [Bot], Yahoo [Bot]