Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'd like to start a tmuxinator session when I login (Gnome on Ubuntu Lucid). I've tried variations of the following but they all execute and close the terminal window. The following have been given to 'Startup Applications'

sleep 10; /usr/bin/gnome-terminal --execute bash -c 'cd /src/thinit;exec bundle exec mux start thinit'
sleep 10; /usr/bin/gnome-terminal --execute bash -c 'cd /src/thinit;bundle exec mux start thinit'
sleep 10; /usr/bin/gnome-terminal --execute bash -c 'cd /src/thinit;exec bundle exec mux start thinit;exec bash'

Update:

This is not an answer, but is getting closer. See Hilltop Yodeler's post about 13u11fr09's suggested solution. The reason this question is not answered is that, AFAICT, it opens another shell session rather than the keep the initial shell session open. In the use case described that is fine - show help, then provide a shell prompt. Whereas here the requirement is to continue to use tmux via the initial shell session launched.

share|improve this question
add comment

2 Answers 2

Don't know anything about tmuxinator so excuse me if offbase here

Your 'Startup Applicaton' is simply a .desktop, typically stored in ~/config/autostart/

What you may want to try is to simplify the Exec=, a number of ways

A start up delay can be set on a new line in the .desktop, Ex.

X-GNOME-Autostart-Delay=10

Additionally you could have the command run in a terminal with a line

Terminal=true

What may also be useful is to consider running your actual command thru a script, then setting the Exec= line to

Exec=/path/to/scriptname

If your script runs fine then it should work ok in the Startup

share|improve this answer
    
The issue is: in 2011 a user should easily be able to set a shell prompt to launch on startup, using Ubuntu's UI. No doubt there is lots of black magic that can be used to get the desired result. This is real a quest of the a simple solution/approach that works with Ubuntu's UI tool for launching apps on startup. –  hedgehog Nov 24 '11 at 3:09
add comment

You have too many execs, and I'm not sure what bundle and thinit are supposed to be, but try this:

sleep 10; /usr/bin/gnome-terminal --working-directory=/src/thinit --execute bundle exec tmux

If you're trying to start the tmux server first, this should work:

sleep 10; /usr/bin/gnome-terminal --working-directory=/src/thinit --execute /bin/bash -c "tmux start; exec bundle exec tmux"
share|improve this answer
    
bundle exec is one Bundler command. See here[0] [0] gembundler.com/man/bundle.1.html –  hedgehog Nov 24 '11 at 2:03
    
I see. And the "start thinit"? Is that supposed to be a particular session? –  Kevin Nov 24 '11 at 2:10
    
Anyway, I've updated it with the bundle exec, if it doesn't work, let me know how it's not working. –  Kevin Nov 24 '11 at 2:28
    
Apologies for the ambiguity: mux start thinit is one command, run in the Ruby gem "environment" that bundle exec sets up/provides. Will try test your suggestions to night, from memory what this did was execute the command and close the gnome terminal window - my recollection maybe faulty so will try again. –  hedgehog Nov 24 '11 at 3:01
    
Perhaps my version of mux is different, but mine doesn't accept an argument to mux start, and mux start starts the server and returns immediately, which would close the terminal. –  Kevin Nov 24 '11 at 3:10
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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