I am using a tool which has an option to set up the command to open a custom terminal. I want to open a terminal to a specified folder (i.e - "/home/user/Desktop"). So far I have just been able to write the command to open a terminal.

xdotool key ctrl+alt+t

How can I open it to open terminal to a specified folder?

I am using ubuntu 14.04


It would be a better and more reliable solution to run the command to open a terminal session instead of pressing ctrl+alt+t via a command. If you are using the default gnome-terminal in Ubuntu 14.04 (Which you probably are if it opens with ctrl+alt+t), then you should try:

gnome-terminal --working-directory=/your/path/here

That should open a terminal session in that directory without any input-related issues that come along with emulating key presses. Also keep in mind that not everyone has the ctrl+alt+t shortcut set up, they might have it disabled.

I hope this helped you!

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.