V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
Trim21
V2EX  ›  问与答

为啥 glob 能匹配到上级目录的文件?

  •  
  •   Trim21 · May 27, 2021 · 779 views
    This topic created in 1799 days ago, the information mentioned may be changed or developed.
    ~/proj/test (master) # echo !(node_modules)**/*.ts
    ../a.ts
    
    ~/proj/test (master) # shopt|grep glob
    dotglob         off
    extglob         on
    failglob        off
    globasciiranges off
    globstar        on
    nocaseglob      off
    nullglob        off
    

    so 搜到了说是可能设置了GLOBIGNORE,但我试了一下这个变量也是空的

    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   983 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 24ms · UTC 21:54 · PVG 05:54 · LAX 14:54 · JFK 17:54
    ♥ Do have faith in what you're doing.