How to open a file in it's own application like start in Windows?
In Windows, at the command prompt, one could type start . and it would open a file browser for the current directory, or start notepad and it would open a new notepad Window.
How to do this in Ubuntu?
Note I am not referring to typing a specific program name like pinta drawing.png, but rather one-fits-all command instead, including one which can be used for file directories (that would be a good start)
2 Answers
xdg-open (ref man xdg-open) is one way of doing it, and this can be aliased to for example the keyword start (which is otherwise not commonly used on Ubuntu):
Add the following to ~/.bash_aliases;
alias start='xdg-open'Logout/login from your current shell (or run the same manually), then try this;
start .It will open current window in Nautilus file browser. God bless!
1To run a program, just type its name directly.
lowriterTo open a document with the associated application, there are several options.
mimeopenβ This is easy for me to remember and doesn't require typing dashes.kde-open/kde-open5β First use is slow.xdg-open(as Roel mentions)
All of them open the default file manager when called to open a directory (including .). There are likely others for different desktop environments (gnome-open).
I wouldn't alias "start" with any of these because it could cause confusion with startx.βIt would also overload the term "start", which conventionally refers to starting services, not opening files.