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'm trying to create an Twitter quicklist desktop file, but I can figured how to resolve one thing.

To compose an message at Twitter, I made the following command: Exec=xdg-open 'https://twitter.com/#!/' && sleep 3 && xdotool key n

(execute)+(open browser)+(Twitter main URL)+ Some seconds to open + Keyboard shorcut to compose.

If I use in terminal, works fine. But in the .desktop file (to make Unity Quicklist) it just doesn't work. Any idea how to fix it?

share|improve this question
add comment

1 Answer 1

up vote 4 down vote accepted

I would use

Exec=sh -c "xdg-open 'https://twitter.com/#!/' && sleep 3 && xdotool key n"
share|improve this answer
    
Work just perfect. Can you just explain what sh em -c mean? (I'm not an advanced Linux programer, hehe) –  euDennis Jan 28 '12 at 20:06
    
@euDennis: you are using &&, that is a shell construct, so you have to use a shell, i.e. sh, or also bash –  enzotib Jan 28 '12 at 20:31
add 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.