V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
sunjourney
V2EX  ›  Bash

为什么 zip 压缩忽略文件使用 zip a.zip a -x '\*.git\*'而不是 -x '.git'

  •  
  •   sunjourney · 2015-10-14 18:00:17 +08:00 · 2649 次点击
    这是一个创建于 3118 天前的主题,其中的信息可能已经有所发展或是发生改变。
    指定忽略.git 不需要通配呀
    2 条回复    2015-10-14 18:44:51 +08:00
    abelyao
        1
    abelyao  
       2015-10-14 18:34:04 +08:00
    .git 是一个文件夹,你还需要忽略该文件夹中的文件;
    另外 .git 有可能是在子目录中,所以前面还需要通配;
    sunjourney
        2
    sunjourney  
    OP
       2015-10-14 18:44:51 +08:00 via iPhone
    @abelyao 感谢^ω^!
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   5696 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 01:46 · PVG 09:46 · LAX 18:46 · JFK 21:46
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.