How to emulate pressing the Close button from a script?

Posted by Karthik on Ask Ubuntu See other posts from Ask Ubuntu or by Karthik
Published on 2012-12-12T15:07:03Z Indexed on 2012/12/12 17:19 UTC
Read the original article Hit count: 362

Filed under:
|

I wanted Thunderbird to stay in the Background to notify me of incoming mails.

After a bit of searching, I found this post.
How to keep Thunderbird and Pidgin running on background?

The solution is to install an addon so that when we close Thunderbird it just stays in the background.

Now, to have thunderbird running at Start up we can just add it to Startup Applications.

But, when I open my system, Thunderbird also gets opened and I have to manually press the close button everytime to make Thunderbird go into the background.

The solution given in the above post for this problem is to select Minimize on start. But doing so affects the way in which Thunderbird works when invoked from the Messaging menu. So I deselected this option.

But, if there is a way to emulate pressing the Close button from a script, I can just add that script to Startup Applications

So is there a way to achieve this?

Note : If there is a simpler way to solve my original problem of keeping Thunderbird in background please post that also.

Many thanks.

© Ask Ubuntu or respective owner

Related posts about scripts

Related posts about thunderbird