从Cygwin打开一个文件(Open a file from Cygwin)
在cygwin中有相当于OSX open命令。 open打开一个包含该类型的默认应用程序的文件。
我想做一些类似的事情
$ magic-command file.xls #excel opens as if file.xls would have been double-clicked $ magic-command file.txt #notepad opens as if file.txt would have been double-clicked你得到这个想法?
基本上就像一个“cygwin-double-click”命令。
Is there an equivalent to OSX open command in cygwin. open opens a file with the default application for that type.
I want to do something like
$ magic-command file.xls #excel opens as if file.xls would have been double-clicked $ magic-command file.txt #notepad opens as if file.txt would have been double-clickedYou get the idea?
Basically something like a "cygwin-double-click" command.
最满意答案
您也可以使用cygwin实用程序:
cygstart <your file>要使OSX类似的东西将以下内容添加到您的bashrc中
alias open='cygstart'不要忘记查看cygstart的手册页。
You can also use the cygwin utility:
cygstart <your file>To make things OSX-like add the following to your bashrc
alias open='cygstart'Don't forget to check out the man page for cygstart.
更多推荐
发布评论