When I press CtrlAltt, the terminal is open in $HOME dir.
I want to open it in /tmp instead.
Thus:
- CtrlAltt
- Terminal is open at
/tmp
Is it possible?
How can I configure it?
When I press CtrlAltt, the terminal is open in $HOME dir.
I want to open it in /tmp instead.
Thus:
/tmpIs it possible?
How can I configure it?
By adding cd /tmp to your .bashrc, bash will go to /tmp directly after you open a Terminal.
This will open a terminal at the /tmp directory.
$ mate-terminal --working-directory=/tmp/
.bashrcmay confuse some scripts. At a minimum,.bash_loginwould be better. – chrylis -cautiouslyoptimistic- Aug 16 '20 at 01:25.bash_loginshouldn't be used for this. The shell in a graphical terminal application (Ctrl+Alt+T) in Ubuntu--and just about any GNU/Linux system--isn't a login shell so none of.profile,.bash_profile, or.bash_loginis sourced. Also, creating.bash_login(or.bash_profile) causes bash to source it instead of, rather than in addition to,.profile, for login shells (as one gets when logging in on a virtual console or via SSH). On Ubuntu, the default contents of.profileare substantial.cd /tmpin.bashrcis fairly safe if placed at the end. – Eliah Kagan Aug 16 '20 at 17:12