jump to navigation

gnome-open: Open Anything from the Command Line December 16, 2006

Posted by Carthik in commands, gnome, guides, ubuntu.

There is a command called gnome-open which I find very handy. I thought of sharing it with you, and was searching for documentation on it, and found none, neither on the web using google, nor on the system. No man page entry, or info entry. All the more reason I should document what I know about it.

Simply put, the command
gnome-open opens the item specified by the url with the preferred GNOME app for that file/mime-type.

In a sense, this command resembles the universal “open” command on Mac OSX.

Read on for examples…

Examples include:
gnome-open google.com
This will open the specified website in your preferred browser

gnome-open mailto:someone@example.com
This will start a new email to the specified address in your preferred mail client

gnome-open .
This will open the current directory you are in, using Nautilus

gnome-open ./Documents/
This will open the specified directory using Nautilus

gnome-open star.pdf
Will open star.pdf in Evince, or your preferred pdf reader

gnome-open foo.txt
Will open foo.txt in a text editor

This goes on, for all possible mime types.


1. Jonh Wendell - December 16, 2006

For simplicity, i’ve put in my .bashrc:
alias g=’gnome-open’

So, to open current dir in nautilus: g .

2. Thomas David Baker - December 16, 2006

I guess this is the program called by the “Run Application” dialog. I am always sticking URLs and file names and directory paths in there and it’s behaviour is similar.

www.scorespro.com - January 26, 2015

The rocks Hockey is usually one sport that is certainly played across the world in unique regions. It fuses the cuboid crushing checks while using the gracefulness connected with sliding along the ice.

3. Szdavid’s Blog » Weblog de David SZERMAN » Blog Archive » Gnome-open, une seule commande pour tout ouvrir - December 16, 2006

[…] Amusez vous bien ! Source […]

4. hype - December 16, 2006

The alias should be:
alias g=’gnome-open’

5. hype - December 16, 2006

Ok, my bad.
You probably pasted the good alias because mine didnt display properly neither :p

6. Vincent - December 16, 2006

I guess this is the program called by the “Run Application” dialog. I am always sticking URLs and file names and directory paths in there and it’s behaviour is similar.

Now that was helpful, thanks a lot!

7. gnome-open: Open Anything from the Command Line « Tuxicity’s source - December 16, 2006

[…] I checked Ubuntu-planet and read this post, and wow ever cool tool nifty gnome-open!, never heard of but man is it handy so check it out. […]

8. Will - December 16, 2006

Love these command line tips.
Thanks for sharing!

9. Ubuntu Tutorials - December 16, 2006

This is a good tip. Thanks. I’m surprised this isn’t documented anywhere else. I’m sure that wont last much longer.

10. Stefan - December 16, 2006

Xfce 4.4 users can use exo-open in the same way.

xdg-open from Xdg-utils can also be used; it uses gnome-open in GNOME, exo-open in Xfce, and the corresponding method in KDE.


11. kbglob - tecnologia para geeks, no para tu mamá » Abriendo archivos con el programa adecuado - December 16, 2006

[…] Uno de los blogs de Ubuntu resaltó una funcionalidad que creo que pocos conoces, pero es muy útil. gnome-open Con este comando podemos abrir cualquier archivo o URL desde consola con el programa asociado en gnome. […]

12. globelovers - December 17, 2006


13. plubius - December 17, 2006

Good advice.

14. Hameed Khan - December 17, 2006

Thanks for such a nice tip! You’ve a very nice blog, keep it going!

15. Ritesh Khadgaray - December 17, 2006

One bug, try gnome-open gedit.desktop or any desktop file. It opens the desktop file in gedit.

16. Tim Lord - December 17, 2006

What about the opposite? 🙂 There’s probably a way to do this, and I just don’t know it, but I frequently find that while I’m viewing files in nautilus that I want to perform some action on them which is easier from the command line (though there are new and cool tools all the time to make this less of a temptation, like SoundConvertor), and I wish I could hit a button somewhere on the navigation panel that would open the same directory in a terminal window. (Rather than — lazy me — starting a terminal and navigating to the same spot. Why be redundant? :))

17. ubuntonista - December 18, 2006
18. Martin - December 18, 2006

Wow, I’ve been looking for this command for ages. Thanks!

19. Tim Lord - December 19, 2006


Thanks! Perfect. Now to install it …


20. Open everything with gnome-open » Linux by Examples - December 19, 2006

[…] For those who prefer command line over mouse-clicking, GNOME provides a nice, simple command that does the job (thanks to Carthik’s discovery!): […]

21. Eric Lake - December 21, 2006

That is one slick command. Thanks for posting it.

22. elton lus minetto » Blog Archive » gnome-open - December 22, 2006

[…] Lendo este blog encontrei uma documentao sobre o comando gnome-open. A funcionalidade a mesma do open do OSX. Exemplos: […]

23. gnome-open: Executando seus programas via linha de comando « TchUbuntu - A Liberdade dos Pampas!! - December 23, 2006

[…] Lendo este blog encontrei uma documentação sobre o comando gnome-open. A funcionalidade é a mesma do open no OSX. […]

24. rabsteen » Blog Archive » links for 2007-01-07 - January 6, 2007

[…] gnome-open: Open Anything from the Command Line « Ubuntu Blog (tags: linux tips ubuntu) […]

25. burchill.net » Blog Archive » Start - February 2, 2007

[…] I was using my Ubuntu system and wanted to do something similar. The command it turns out is gnome-open. Bit of a mouthful so I have this aliased in my .bashrc file to cs for either cygstart or gnome […]

26. Peter76 - February 4, 2007

anybody knows how to change the prefered application used by gnome-open?

27. Peter76 - February 4, 2007

EDIT: meaning through the command line , not through nautilus:-)

28. matias - February 16, 2007

This was all very nice. Worked to. Just one question:
Why did this appear?

warning – incompatible stripping characters and condition:
SFX D ar rar [^fmk]er
warning – incompatible stripping characters and condition:
SFX U �re orde ere
warning – incompatible stripping characters and condition:
SFX U �re ort ere

29. Brad Parks - March 9, 2007

This is probably obvious to someone out there, but I find that the run dialog doesn’t recognize any aliases I have in my .bashrc… For example, I’ve got an alias for another terminal setup to be “cmd”, and when I’m in a terminal and type “cmd”, another terminal window pops up, just like I expected.

But when I type “cmd” in the Run Application Dialog, it doesn’t recognize the allias. Does anyone know how to fix this?

Thanks in advance!

30. madhusudhana - April 19, 2007

Thanks for your information.
Really I struggled a lot before knowing this.
Now I came to know it from you how to open files from command window.

Thanks and regards.

31. Asad - March 11, 2008

help help help. i saw some expert r here, please help me i just installed Ubuntu7.10, even i dont know how it will work google and youtube help me ALOT to install ubuntu but i dont know how to install software on it i want to install YAHOO AND MSN and others software, how can i do it plz help me

32. mocazoasia - April 8, 2008

Mobile downloads for all mobiles of latest Bollywood Wallpapers, Celebrity Gossips, Ring tones, Themes, Cricket, Games, and Mobile fun-Bringing Asian Lifestyle to your Mobile. Instant downloads to Mobile for UK.More details visit:http://www.mocazoasia.com/

33. Cosmin - May 30, 2008

Excellent advice and helpful comments. Maybe you could include some of them in the original posts.

34. slchen - June 29, 2008

gnome-open trash:
can popup a trash can
gnome-open ~/Desktop
can popup a desktop folder

I think there is more internal tag to operate the behavior of nautilus.

35. deejack - September 30, 2008

How to edit Gnome’s “Open With” list?

36. Brad Parks - October 9, 2008

Does anyone know how to make gnome-open or the “Run application” dialog recognize aliases in my ~/.bashrc ? I’ve got some in there that I’d love to have available to either, but my aliases aren’t recognized!

37. marnie - October 19, 2008

i tried using the gnome-open command gnome-open http://www.website.com, it only open the firefox web browser; it did not open the specified website.

38. uneveneraser - October 23, 2008

thanks thanks

39. sachin - October 26, 2008

can anyone tell me how to cloase a browser using command

40. Merging PDFs and the lovely gnome-open | tail -f findings.out - December 23, 2008

[…] it opens right up in Document Viewer (or whatever your preferred app for PDFs is set to). See more examples here. I also added an alias “go”, since that’s a lot shorter and more […]

41. herman - March 20, 2009

how to use the terminal in ubuntu 8:10
and what you should do in to open file?
ex cd .. /
/ etc /
/ var / wwww /
help me please…..

42. ghnd - March 27, 2009

thanks a lot for this update !
i user os x 10.5.5 and the “open” command will do fine!

when i tried the same within ubuntu i first had to install sox “sudo apt-get install sox”and could not use i though. now it works thanks to you with “gnome-open”

43. jayesh - April 9, 2009

since this blog is CLOSE to UBUNTU…..i guess u can help me out…
see,i need to add a new option when you Right Click on desktop or any icon……
actually i need the commands to do the above….
thnx in advace!

44. irfan - July 6, 2009

Oops..for me gnome-open is not working..
.it looks like this…help me please..

irfan@irfan-laptop:~$ gnome-open google.com
Error showing url: Error stating file ‘/home/irfan/google.com’: No such file or directory

irfan@irfan-laptop:~$ gnome-open http://www.google.com
Error showing url: Error stating file ‘/home/irfan/www.google.com’: No such file or directory


45. subogero linux blog » There is Tao in Windows - August 6, 2009

[…] something similar on the internet, and all I found was the “gnome-open” command. The blog-post has ecstatic […]

46. subogero - August 10, 2009

Please check my “go” script, which can open any URL or start an application as well.

47. mpande - October 31, 2009

Thanks alot, it play a great to me. I appriciate it .

48. Xandro - December 24, 2009

wow, thanks so much,
I’m new to linux, and after finishing an online beginner course I couldn’t believe a command like this didn’t exist.
Thanks for the tip, I’ll go create an alias right now

ps: why the hell isn’t this documented anywhere else?

49. SK2108 - April 8, 2010

gnome-open works fine, but I am running KDE and KDE has a different default set of applications. Is there a similar command that will use the KDE default apps instead of the gnome defaults?

patrick - May 20, 2010

try kde-open

50. porno - June 2, 2010

Firefox 3 users, rejoice! Today I’m pleased to announce a beta release of an enhanced version of our Firefox Add-on for del.icio.us that now has full Firefox 3 support while retaining Firefox 2 compatibility. While it is largely similar to the release version of our Firefox Add-on, there are a few nifty new features:

51. porno - June 28, 2010

porno izle sex videoları seyret

52. porno - July 22, 2010

thanks admin

53. porno - September 26, 2010

woow Nice Post. Thnx my friend.i like this

54. sikiş izle - September 26, 2010

The alias should be:

55. antalya ilaçlama - September 27, 2010

I guess this is the program called by the “Run Application” dialog. I am always sticking URLs and file names and directory paths in there and it’s behaviour is similar.

56. porno sikiş - September 27, 2010

One bug, try gnome-open gedit.desktop or any desktop file. It opens the desktop file in gedit.

57. sex sikiş - September 28, 2010

anybody knows how to change the prefered application used by gnome-open?

58. No Title | Reflections Technology - November 22, 2010
59. keçiören nakliyat - December 3, 2010

evden eve Thanks to

60. faydalı bilgiler - February 16, 2011

Thanks bilgiportali

61. Richard - June 21, 2011

Best think I have learn since I started using ubuntu. Since I love the console and hate browsing image from nautilus.

62. andymiken - July 14, 2011

Many thanks sharing fantastic informations. Ones websiteis consequently cool. We are impressed from the main factors that you’ve with this blog. The item reveals precisely how nicely people perceive this specific subject. Thank your share with me! http://www.fakeray-bansunglasses.com.

63. arkadaş - July 23, 2011

Fantastik bir bilgi paylaşım çok teşekkürler. Ones dolayısıyla serin websiteis. Biz bu blogu olduğunuz ana etkenlerden etkilendik. Öğesi, insanların bu özel konuda nasıl algıladıkları güzel tam ortaya koymaktadır . Benimle paylaşmak teşekkür ederiz

64. ukrayna vizesi - July 30, 2011


65. arkadaş - August 5, 2011

teşekürler bilgi için elinize sağlık

66. Rodolfo - July 26, 2013

I have read so many articles or reviews about the blogger lovers however this
article is genuinely a pleasant piece of writing, keep
it up.

67. Nike Air Max 1 - April 26, 2014

Hi there! I could have sworn I’ve visited this blog before but after going through many of the articles
I realized it’s new to me. Nonetheless, I’m certainly pleased I discovered it
and I’ll be book-marking it and checking back often!

68. islamic Quotes - May 2, 2014

I’m not sure why but this site is loading very slow for me.
Is anyone else having this problem or is it a issue on my end?
I’ll check back later on and see if the problem still exists.

69. crédit rapide sans justificatif - May 23, 2014

Pas facile de trouver de bonnes études sur ce sujet, c’est fait grâce à
ce site, super et encore bravo.

70. https://www.rebelmouse.com/tedswoodworkingplansreviewed/ - May 28, 2014

As the ceremony drew ever closer, the Luxembourg royal family finally arrived.
14 years after his first title shot, he lost by 11th round TKO to
another Argentine, Mariano Carrera. In addition, a real handbag
is exclusive to Hermes.

71. http://jack74pin.buzznet.com/user/links/3412525/lost-secret-braun-coffee-maker - June 17, 2014

Every weekend i used to visit this website, for the reason that i wish for enjoyment, since this this web site conations really fastidious funny stuff too.

72. jual beli wanita - July 30, 2014

With creating so much written content do you ever run into any issues of plagiarism or copyright violation? My website has a lot of unique content I’ve either authored myself or outsourced but it seems a lot of it is popping
it up all over the internet without my agreement.

Do you know any techniques to help protect against content from being stolen? I’d definitely appreciate it.

73. Bare Minerals skin care treatment - September 8, 2014

Outstanding post however I was wondering if you could
write a litte more on this topic? I’d be very thankful if you could elaborate a little bit more.

74. https://www.facebook.com/ - September 21, 2014

The film festival takes place in the Midlands region of England and they call for submissions
in June. No strategies involved the day and time suited me and so did it.
But one drawback is that hair will grow back quite fast
as the cr.

75. partouze Hardcore - September 26, 2014

Une fois de pluѕ un article réellement captivant

76. free Dentist games - September 29, 2014

If you are going for best contents like me, simply visit this web
page daily since it offers feature contents, thanks

77. Tawnya - October 3, 2014

When some one searches for his necessary thing, soo he/she wants to
be available that in detail, therefore that thing is maintained over here.

78. Maricela - October 12, 2014

May I just say what a comfort to find somebody that really understands what they’re discussing on the internet.
You certainly know how to bring a problem to light and make it important.

More and more people really need to look at this and understand this side of your story.
It’s surprising you aren’t more popular given that you definitely have the gift.

79. partouze hard - October 12, 2014

Je sսis tout à fait du même avis que vous

80. jeune cochonne - October 13, 2014

Hummm êtеѕ vous sûr de ce que vous avancez ?

81. Heart Revitalized Program - October 20, 2014

Then we hand these Heart Revitalized answer lists
over to the group of professional reviewers for in deep analysis.
Heart Revitalized program gives a super easy and immediate good results by the use of a on daily basis plan of fifteen minutes.

82. droid.ws - October 22, 2014

Retrieved on February 28, 2010 from Genetic Health:.
In fact, many of the early symptoms of RA often include foot problems.
The rehabilitation of heroin users similarly entails use of medicines during the detox from heroin addiction procedure.

83. handdouchehouder - November 16, 2014

This is a wonderful article, Given so much info in it, These type of articles keeps the users interest in the website, and keep on sharing more

84. bigeyelending.com - December 1, 2014

This blog wɑs… how do you say it? Relevant!! Finally I’ve found something whichh helped me.

85. خرید vpn - December 12, 2014

very good

86. designer jewelry - December 13, 2014

As a businessperson, you will have greater access to resources such
as catalogs and trade shows. And when everyone else is smiling, you’re sure
to be smiling soon enough as well. You can even consider the silver
storage boxes specially designed to resist tarnish.

87. Lorri - December 22, 2014

naturally like your web-site but you need to test the spelling on quite a few of your posts.

Many of them are rife with spelling problems and I to find it very
troublesome to inform the reality then again I will definitely come back again.

88. ヴィクトリアシークレット ビキニ - January 5, 2015

You actually mentioned that superbly!
xunjie 新世代内外IWC IW379503ダイビング安全システムを装備した特別仕様車を考慮した場合に、
Appleは「IPAD」商標の譲渡契約チェンPibiao中国本土を生産している、 󥹥`ө`
ۥ inxxすべての若い人たちは、
この純粋にアメリカの協力は、 󥯥` ǥ`
㥱å ユニークShoumoもっと写真をクリックファッショナブルな衣類のJASONWOODを着アスカシーンがステージ上で歌った。
他の衣類と一致させることができます。ȥꥢ`å ˮ ͨ؜ 黒と白のハイヒールオックスフォードシューズの後に改築、
MOTO XT615風水李はあなたのすべてのタイプごとに1のための完全なあなたのファッションアクセサリー、
一緒に外資系企業(勝男ジュエリー)、 ǥ ˩`` å

89. sexe cochonne - January 22, 2015

Јe suis еntièrement en accord avec vous

90. jeune salope - January 30, 2015

Excellent аrticle : j’en discuterai dans la journée aνеc des potes

91. immigration lawyer in md - February 14, 2015

immigration lawyer in md

gnome-open: Open Anything from the Command Line | Ubuntu Blog

92. ชาทีมิกซ์ - March 10, 2015

Hey there I am so happy I found your webpage,
I really found you by error, while I was browsing on Digg for something else,
Nonetheless I am here now and would just like to say thank you for a tremendous post and a all round thrilling blog (I also love the theme/design), I don’t have time to read through it all at the minute
but I have book-marked it and also included your RSS feeds,
so when I have time I will be back to read a great deal more, Please
do keep up the fantastic work.

93. helpfulcheats.com - March 16, 2015


gnome-open: Open Anything from the Command Line | Ubuntu Blog

94. rencontre sexe bayonne - November 13, 2015

hi!,I really like your writing very so much! proportion we keep uup a correspondence
more approximately your article on AOL? I need ann expert
in this area to resolve my problem. May
be that is you! Looking ahead to peerr you.

95. that guy - September 5, 2019

that guy

gnome-open: Open Anything from the Command Line | Ubuntu Blog

96. Como abrir um arquivo PDF a partir da linha de comando no Ubuntu - Criarfazer.net - November 6, 2019

[…] Abra qualquer coisa na linha de comando […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: