aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaria Lisina <sekoohaka.sarisan@gmail.com>2026-03-12 08:50:34 +0300
committerMaria Lisina <sekoohaka.sarisan@gmail.com>2026-03-12 08:50:34 +0300
commitae8542802ca1ade4dce1278cc28d5b74ccb3f329 (patch)
tree83d5e9fb452fef1a2fa619355ee246bc5004709e
parentffd005c1fca44efd49bc1b23287d16b73a5b9cc7 (diff)
bot: Remove wc dependency
Signed-off-by: Maria Lisina <sekoohaka.sarisan@gmail.com>
-rw-r--r--README.md1
-rwxr-xr-xbot.zsh3
2 files changed, 1 insertions, 3 deletions
diff --git a/README.md b/README.md
index 096c9c5..1e9de69 100644
--- a/README.md
+++ b/README.md
@@ -36,7 +36,6 @@ For distribution specific installation commands follow [command-not-found](https
* sleep
* tail
* tar
-* wc
## Deployment
diff --git a/bot.zsh b/bot.zsh
index d2b9155..957742d 100755
--- a/bot.zsh
+++ b/bot.zsh
@@ -72,7 +72,6 @@ busybox=(
sleep
tail
tar
- wc
)
if [[ -n "${1}" ]]
@@ -711,7 +710,7 @@ then
fi
help_line_counter=1
-help_max_line=$(($(wc -l <<< "${file_content}" | cut -d ' ' -f 1) + 1))
+help_max_line=$(($(grep -c '' <<< "${file_content}" | cut -d ' ' -f 1) + 1))
until [[ ${help_line_counter} -eq $((help_max_line + 1)) ]]
do