Don't run a command you don't know

HI:
yesterday I was trying to make zsh default bash So I searched online and found this:

https://askubuntu.com/questions/131823/how-to-make-zsh-the-default-shell

sudo nano ~/.bashrc

then add the line below top of the file

exec zsh

After this, I modified the file
bashrc and you added

exec zsh

This is why the distro does not work

so kde not working to try it work again i must go to tty and write startx

It’s just only (as non-root user):

chsh -s /bin/zsh

sudo in your $HOME – this man definitely not understand what write :joy:

2 Likes

By editing that file the way you did, you gave ownership to root, so now your user likely can’t use it. You need to give it back.

sudo chown $USER:$USER $HOME/.bashrc

Also, i think messed up the formating of your post.

3 Likes

On KDE you change the shell from Konsole settings, when you modify a custom profile.

While entirely in line with this topic, don‘t you fear some poor idiot is going to try just that? After all this is a respected tech and support forum.

1 Like

To change default for you (not for root - which won’t have access to your .zsh anyway) , you do sudo chsh -s /bin/zsh ME

Beware of askubuntu. It’s a bit like signing up for a cookery course at a pig farm… and some solutions which suit Debian distributions are just waaaaay off track.

Anyway, after installing zsh, you should find a .zsh file in ~/home/ME - and when you do, it’s a good plan to make a new alias:

alias zshconfig='code ~/.zshrc &'
alias reload='source ~/.zshrc'

So it’s simpler to open and edit the config whilst using the terminal, and you can simply type ‘reload’ when you made an edit.

Next time our OP goes searching, hopefully a little more enlightened, search internet for ‘install zsh’ and ‘set zsh as default shell’ and ‘set zsh as default shell for me’.

You get the idea.

I apologize, my English is poor and I could not understand you well

1 Like

thank you @Ben

My pleasure - I did some stupid things in my time.
It’s only stupid to me now that I have reinstalled 100 times and now manage to mostly avoid it :wink:

1 Like

That’s not how it works on KDE.

Hmmm confused now.

I remembering installing zsh (maybe with pacman -S zsh)
Then I think I did

chsh -s $(which zsh)
❯ which zsh
/usr/bin/zsh

Sooo… chsh -s $/usr/bin/zsh

Right?

As already said, to change the shell in KDE, you go into the terminal (Konsole) settings for the profile, and you change the shell command here.

Using chsh will not change the shell of KDE’s terminal. It will change the user shell only, which is not the setting used in Konsole, KDE’s terminal emulator.

5 Likes

I have to apologize @iiismaein , I replied exclusively to comment of somebody else, who made a joke that would have deleted the whole system if somebody would have followed it.
My response was not suited to help you with your problem.

2 Likes

better see with this

pacman -Ss zsh
pacman -Si manjaro-zsh-config