I'm using ruby version manager rvm which requires its commands to be run in a login shell.

gnome-terminal provides an option for commands to run as a login shell as described here.

however, there's not any similar option in patheon-terminal. is there a work around for this issue?

  • for now I have to run bash --login everytime I open a terminal, which is inconvenient imo. – Aboud Zakaria Dec 28 '16 at 13:27

Setting the shell key to bash --login doesn't work, however I managed to fix that with the following workaround:

create a file named bashlogin in /bin directory with the following content

exec bash --login

mark it as executable

sudo chmod +x /bin/bashlogin

and finally set the terminal shell key

gsettings set io.elementary.terminal.settings shell 'bashlogin'

| improve this answer | |
  • FYI, the setting location has changed in ElementaryOS 5.0 Juno. It's now located in gsettings set io.elementary.terminal.settings shell 'bashlogin' – Evan Plaice Jan 17 '19 at 10:22
  • the answer is updated now – Aboud Zakaria Jan 20 '19 at 15:20

You can set the key shell under org.pantheon.terminal.settings in dconf-editor or via the command line:

gsettings set org.pantheon.terminal.settings shell 'bash --login'
| improve this answer | |
  • It doesn't work, terminal now hangs and shows no shell prompt. – Aboud Zakaria Dec 31 '16 at 9:46
  • 2
    it seems that the shell key doesn't accept commands with arguments. – Aboud Zakaria Dec 31 '16 at 9:57
  • @AboudZakaria My terminal hangs, too. How can I recover it? – Aetherus Zhou Aug 15 '19 at 1:41

If like me you use zsh :


exec bash --login

by :

exec zsh --login
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.