From a76b20672e35f017658b0c6c9215ea8f3f6885b3 Mon Sep 17 00:00:00 2001 From: sigoden Date: Sat, 17 Aug 2024 11:59:29 +0800 Subject: [PATCH] chore: update readme --- README.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/README.md b/README.md index 995cfd1..d0949bc 100644 --- a/README.md +++ b/README.md @@ -236,6 +236,29 @@ man man/example.1
+## MacOS + +The built-in Bash in macOS is version 3.2 (released in 2007), and the known tools (ls, cp, grep, sed, awk, etc.) are based on BSD. +For better functionality and compatibility, it is recommended to install Bash version 5 and GNU tools. + + + +Use `brew` to install Bash and GNU tools: + +```sh +brew install bash coreutils gawk gnu-sed grep +``` + +And update the `PATH` environment variable: +```sh +export PATH="/opt/homebrew/opt/coreutils/libexec/gnubin:/opt/homebrew/opt/gawk/libexec/gnubin:/opt/homebrew/opt/gnu-sed/libexec/gnubin:/opt/homebrew/opt/grep/libexec/gnubin:$PATH" +``` + +
+ +
+ + ## Windows The only dependency for `argc` is Bash. Since most developers working on Windows have [Git](https://gitforwindows.org/) installed, which includes Git Bash, you can safely use `argc` and GNU tools (like `grep`, `sed`, `awk`, etc.) in the Windows environment.