3 पॉइंट द्वारा GN⁺ 2024-07-23 | 1 टिप्पणियां | WhatsApp पर शेयर करें

eza

eza परिचय

  • eza Unix और Linux ऑपरेटिंग सिस्टम में डिफ़ॉल्ट रूप से दिए जाने वाले फ़ाइल सूची कमांड ls का एक आधुनिक विकल्प है
  • यह फ़ाइल प्रकार और metadata में अंतर दिखाने के लिए रंगों का उपयोग करता है
  • यह symbolic links, extended attributes और Git को पहचानता है
  • यह छोटा, तेज़ है और एक single binary के रूप में उपलब्ध है
  • इसका लक्ष्य ls का उपयोगकर्ता-अनुकूल और फीचर-समृद्ध विकल्प बनना है

eza की मुख्य विशेषताएँ

  • exa 2021 में उत्पन्न हुए "grid bug" का समाधान
  • hyperlink support
  • mount point विवरण प्रदान करता है
  • Selinux context आउटपुट
  • Git repository status आउटपुट
  • आसानी से पढ़ी जा सकने वाली relative date display
  • कई security fixes
  • bright terminal colors support
  • कई छोटे bug fixes और बदलाव

इंस्टॉल करने का तरीका

  • eza Windows, macOS, Linux पर उपलब्ध है
  • प्लेटफ़ॉर्म और distribution के अनुसार इंस्टॉलेशन निर्देश INSTALL.md में देखे जा सकते हैं

कमांड लाइन विकल्प

डिस्प्ले विकल्प

  • -1, --oneline: एक पंक्ति में एक आइटम दिखाएँ
  • -G, --grid: आइटमों को grid रूप में दिखाएँ (डिफ़ॉल्ट)
  • -l, --long: विस्तृत विवरण और attributes दिखाएँ
  • -R, --recurse: directories को recursively browse करें
  • -T, --tree: directories को tree रूप में recursively browse करें
  • -x, --across: grid को horizontal रूप में align करें
  • -F, --classify=(when): फ़ाइल नाम में type indicator दिखाएँ (always, auto, never)
  • --colo[u]r=(when): terminal colors कब उपयोग करने हैं सेट करें (always, auto, never)
  • --colo[u]r-scale=(field): field के स्तरों में अंतर दिखाकर highlight करें (all, age, size)
  • --color-scale-mode=(mode): --color-scale में fixed colors या gradient का उपयोग करें (fixed, gradient)
  • --icons=(when): icons कब दिखाने हैं सेट करें (always, auto, never)
  • --hyperlink: आइटमों को hyperlink के रूप में दिखाएँ
  • --absolute=(mode): आइटमों को absolute path के साथ दिखाएँ (on, follow, off)
  • -w, --width=(columns): स्क्रीन की चौड़ाई columns में सेट करें

फ़िल्टरिंग विकल्प

  • -a, --all: hidden files और dot files दिखाएँ
  • -d, --list-dirs: directories को सामान्य files की तरह सूचीबद्ध करें
  • -L, --level=(depth): recursive depth सीमित करें
  • -r, --reverse: sorting order उल्टा करें
  • -s, --sort=(field): sort करने के लिए field सेट करें
  • --group-directories-first: directories को अन्य files से पहले सूचीबद्ध करें
  • -D, --only-dirs: केवल directories सूचीबद्ध करें
  • -f, --only-files: केवल files सूचीबद्ध करें
  • --no-symlinks: symbolic links न दिखाएँ
  • --show-symlinks: symbolic links को स्पष्ट रूप से दिखाएँ
  • --git-ignore: .gitignore में उल्लिखित files को अनदेखा करें
  • -I, --ignore-glob=(globs): अनदेखा करने वाली files के glob patterns सेट करें

long view विकल्प

  • -b, --binary: फ़ाइल आकार को binary prefix के साथ दिखाएँ
  • -B, --bytes: फ़ाइल आकार bytes में दिखाएँ
  • -g, --group: प्रत्येक फ़ाइल का group दिखाएँ
  • -h, --header: प्रत्येक column में header row जोड़ें
  • -H, --links: प्रत्येक फ़ाइल के hard links की संख्या दिखाएँ
  • -i, --inode: प्रत्येक फ़ाइल का inode number दिखाएँ
  • -m, --modified: modified timestamp field का उपयोग करें
  • -M, --mounts: mount विवरण दिखाएँ (केवल Linux और MacOS)
  • -S, --blocksize: allocated filesystem block size दिखाएँ
  • -t, --time=(field): उपयोग किए जाने वाले timestamp field को सेट करें
  • -u, --accessed: accessed timestamp field का उपयोग करें
  • -U, --created: created timestamp field का उपयोग करें
  • -X, --dereference: फ़ाइल जानकारी के लिए symbolic links को dereference करें
  • -Z, --context: प्रत्येक फ़ाइल का security context दिखाएँ
  • -@, --extended: प्रत्येक फ़ाइल के extended attributes और size दिखाएँ
  • --changed: changed timestamp field का उपयोग करें
  • --git: प्रत्येक फ़ाइल की Git status दिखाएँ
  • --git-repos: प्रत्येक directory की Git status दिखाएँ
  • --git-repos-no-status: केवल यह दिखाएँ कि directory Git repository है या नहीं (तेज़)
  • --no-git: Git status न दिखाएँ
  • --time-style: timestamp format सेट करें
  • --total-size: recursive directory size दिखाएँ
  • --no-permissions: permissions field न दिखाएँ
  • -o, --octal-permissions: प्रत्येक फ़ाइल की permissions को octal format में दिखाएँ
  • --no-filesize: filesize field न दिखाएँ
  • --no-user: user field न दिखाएँ
  • --no-time: time field न दिखाएँ
  • --stdin: stdin से फ़ाइल नाम पढ़ें

eza में योगदान कैसे करें

  • eza में योगदान करने के लिए पहले code of conduct का पालन करना होगा
  • code of conduct समझने के बाद वास्तविक hacking से जुड़ी जानकारी के लिए CONTRIBUTING.md देखें

GN⁺ का सारांश

  • eza ls का एक आधुनिक विकल्प है, जो अधिक फीचर्स और उपयोगकर्ता-अनुकूल interface प्रदान करता है
  • इसमें विभिन्न color options और Git status display जैसी उपयोगी सुविधाएँ शामिल हैं
  • यह Windows, macOS, Linux तीनों पर उपलब्ध है और इसे इंस्टॉल करना भी आसान है
  • यह ls जैसा है, लेकिन अधिक options देता है, जिससे file listing का काम अधिक कुशल हो जाता है
  • समान सुविधाएँ देने वाले टूल्स में exa शामिल है

1 टिप्पणियां

 
GN⁺ 2024-07-23
Hacker News राय
  • "human readable dates" असुविधाजनक हैं। डायरेक्टरी लिस्टिंग में तारीख और समय देखना चाहते हैं

    • उदाहरण के लिए, "1 day ago" की जगह सटीक समय दिखाना चाहते हैं
    • यह infinite scroll का नतीजा भी हो सकता है
  • lsd भी है, लेकिन eza को पसंद करते हैं

    • आधुनिक command-line tools की सिफारिश
      • bat - highlighting फीचर वाला cat
      • difftastic - बेहतर diff
      • gdu - SSD के लिए disk space analyzer
      • zoxide - आधुनिक cd
      • fd - find का विकल्प
      • rg - ripgrep (grep)
      • fzf - fuzzy finder
      • jless - mouse folding फीचर वाला JSON viewer
      • dra - release assets डाउनलोड और install करने का टूल
      • lazygit - Git TUI
      • lazydocker - Docker TUI
      • yazi - image preview वाला file manager
      • zellij - बेहतर tmux / screen
      • starship - cross-shell prompt configuration
  • GNU ls का रखरखाव हो रहा है

    • हाल के commits हैं (2024-06-24, 2024-06-27)
    • GNU Coreutils mailing list भी सक्रिय है
  • fish shell पर स्विच करने के बाद ls का उपयोग 100% कम हो गया

    • Alt + l कमांड से डायरेक्टरी की सामग्री दिखती है
    • shell history के नतीजे अधिक साफ़ हैं
  • file type अलग करने के लिए colors इस्तेमाल करने वाले terminal tools से समस्या है

    • आंखों के लिए आरामदायक terminal background इस्तेमाल करते हैं
    • color scheme background से टकराती है या देखना मुश्किल होता है
    • ls या ls के विकल्प के output में colors नहीं चाहिए
    • ls -AFC output पर्याप्त है
  • यह जानना चाहते हैं कि GNU utilities के नए versions MIT license के साथ build क्यों किए जाते हैं

  • README में eza के exa का fork होने का ज़िक्र न होना अजीब लगता है

  • qwerty keyboard पर eza टाइप करना असुविधाजनक है

    • ls एक तेज़ key combination है
    • alias इस्तेमाल कर सकते हैं, लेकिन compatibility issues वगैरह के कारण अजीब लगता है
  • eza/exa की मुख्य विशेषता सुंदर colors नहीं बल्कि git integration है

    • file listing में अलग-अलग files की git status देखी जा सकती है (ignored, modified आदि)
  • ls का इस्तेमाल करने वाले लोग लगभग नहीं हैं

    • tab completion से ज़रूरी files की सूची मिल जाती है
    • यह दावा क्यों किया जाता है कि ls का अब रखरखाव नहीं हो रहा, यह जानना चाहते हैं