thenewbie
V2EX  ›  问与答

ubuntu的文本文件在mac里的打开方式?

  •  
  •   thenewbie · Mar 1, 2012 · 4246 views
    This topic created in 5268 days ago, the information mentioned may be changed or developed.
    在ubuntu里面建立的纯文本文件,木有扩展名的,直接gedit写的那种,貌似到mac里面双击后变成了用终端打开??

    如何批量更改成在mac下可以双击后用编辑器打开啊?除了批量更改文件名为*.txt?
    16 replies    1970-01-01 08:00:00 +08:00
    suhetie
        1
    suhetie  
       Mar 1, 2012
    试过用textedit打开了么?
    thenewbie
        2
    thenewbie  
    OP
       Mar 1, 2012
    @suhetie 可以用textedit或其他软件打开,我想知道如何设置默认就用这些东西打开?现在默认是直接终端打开了.... 难道要一个一个指定打开方式么?有好多....
    suhetie
        3
    suhetie  
       Mar 1, 2012
    @thenewbie 文件属性(cmd+i),然后选择打开方式的那个部分下面有类似“改变所有”的选线
    zhigang1992
        4
    zhigang1992  
       Mar 1, 2012
    开终端,more [文件名]
    thenewbie
        5
    thenewbie  
    OP
       Mar 1, 2012
    @suhetie “改变所有”的话,不能完成此操作。发生意外错误(错误代码 -50)。
    thenewbie
        6
    thenewbie  
    OP
       Mar 1, 2012
    @zhigang1992 呃,有不用终端的办法么?
    zhigang1992
        7
    zhigang1992  
       Mar 1, 2012
    右键-open with-other-找到texteditor就可以了。
    thenewbie
        8
    thenewbie  
    OP
       Mar 1, 2012
    @zhigang1992 有多个的话,如何批量更改呢?
    thenewbie
        9
    thenewbie  
    OP
       Mar 1, 2012
    @suhetie @zhigang1992 多个文件的话,除了批量重命名添加 .txt 扩展名解决这个问题,还有别的方法么?
    run2
        10
    run2  
       Mar 1, 2012
    @thenewbie 用终端打开是因为有运行权限吧 -x
    thenewbie
        11
    thenewbie  
    OP
       Mar 1, 2012
    @sobigfish 在ubuntu下面直接用gedit写的文本文件,没有特别设置过运行权限,发给朋友的air后,他一打开就自动用终端开打开....
    就是纯文字,也不是代码脚本啥的...
    suhetie
        12
    suhetie  
       Mar 1, 2012
    http://superuser.com/questions/231854/default-editor-for-files-without-file-name-extension-in-mac-os-x

    因为没有扩展名,change all无法正常识别和设定。上面的帖子介绍了两种方法,一种转个第三方软件,另一种是直接去该plist。祝好运。
    zhensun
        13
    zhensun  
       Mar 1, 2012
    chmod -x 看看。
    wynnsyt
        14
    wynnsyt  
       Mar 1, 2012
    一个workaround就是直接拖到dock图标上打开吧..
    suhetie
        15
    suhetie  
       Mar 1, 2012
    @thenewbie 回头来看自己打错了两个错字还都在动词上。。。更正如下:上面的帖子介绍了两种方法,一种 装 个第三方软件,另一种是直接去 改 plist。
    thenewbie
        16
    thenewbie  
    OP
       Mar 1, 2012
    @suhetie 嗯!这个链接灰常给力!
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3134 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 36ms · UTC 13:45 · PVG 21:45 · LAX 06:45 · JFK 09:45
    ♥ Do have faith in what you're doing.