Skip to content

Commit 4c399c6

Browse files
Copilotandrejusk
andcommitted
Add ripgrep installation for macOS and Linux
Co-authored-by: andrejusk <[email protected]>
1 parent b26525d commit 4c399c6

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

script/install.d/24-ripgrep.sh

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
#!/usr/bin/env bash
2+
3+
# -----------------------------------------------------------------------------
4+
# Description:
5+
# Install ripgrep.
6+
#
7+
8+
if ! command -v rg &>/dev/null; then
9+
if [[ "$OSTYPE" == "linux-gnu"* ]]; then
10+
sudo apt-get update -qq &&
11+
sudo apt-get install -qq ripgrep
12+
elif [[ "$OSTYPE" == "darwin"* ]]; then
13+
brew install ripgrep
14+
fi
15+
fi
16+
17+
rg --version

tests/test_binaries.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ def in_shell_path(shell: Text, binary: Text) -> bool:
4646
# tools
4747
"git",
4848
"gh",
49+
"rg",
4950
"terraform",
5051
"docker" if not os.environ.get("SKIP_DOCKER_CONFIG") else None,
5152
"neofetch",

0 commit comments

Comments
 (0)