什麼是在大多數或所有Linux上都可用的「open」命令?在桌面上顯示當前目錄的常用Linux命令是什麼?
例如在OS X中,我可以在shell中做
open。
和文件夾顯示在Finder(即桌面) 類似地,在Windows上,該命令是「瀏覽」。
因爲我想要一個emacs中的跨平臺命令。
(defun open-in-desktop()
"Open the current file in desktop.
Works in Microsoft Windows and Mac OS X."
(interactive)
(cond
((string-equal system-type "windows-nt")
(w32-shell-execute "explore"
(replace-regexp-in-string "/" "\\" default-directory t t)))
((string-equal system-type "darwin") (shell-command "open ."))
))
有人建議XDG-開放的,但我不知道這只是KDE的具體的發行或GNOME /。 (我不是Linux用戶)
http://stackoverflow.com/questions/41969/standard-way-to-open-a-folder-window-in-linux – 2011-06-10 02:38:57