News for hackers. Stuff that matters.
Re:Undergrad thought he had mastered Unix in weeks. Then he ... by mmh0000 on Monday November 18, 2024 @11:52AM (#42174250)
It partially depends on Zsh's NOMATCH and NULL_GLOB setopt:

NOMATCH - print error when glob doesn't match;

NO_NOMATCH - print literal GLOB character:

  setopt NOMATCH
  ls * => zsh: no matches found: *

  setopt NO_NOMATCH
  ls * => ls '*'
NULL_GLOB - when glob doesn't match, return blank; (Overrides NOMATCH):

  setopt NULL_GLOB
  ls * => ls ''

  # Brings behavior inline with RHEL/Bash4 defaults:
  setopt NO_NOMATCH

There are no comments on this comment yet.