aboutsummaryrefslogtreecommitdiffstats
path: root/zuwu.zsh
diff options
context:
space:
mode:
authorLibravatarLarge Libravatar memdmp <memdmpestrogenzone>2025-01-03 04:09:28 +0100
committerLibravatarLarge Libravatar memdmp <memdmpestrogenzone>2025-01-03 04:09:28 +0100
commitd470f2eb731ebe48d41ad8d9ccc883efff3b5563 (patch)
tree9d838d35f7c8a4c12364bc19bf66cf390232ff8e /zuwu.zsh
parent5bb8ae174ea1af3f9c727a5ff5d2ff02732f18d8 (diff)
downloadzuwu-d470f2eb731ebe48d41ad8d9ccc883efff3b5563.tar.gz
zuwu-d470f2eb731ebe48d41ad8d9ccc883efff3b5563.tar.bz2
zuwu-d470f2eb731ebe48d41ad8d9ccc883efff3b5563.tar.lz
zuwu-d470f2eb731ebe48d41ad8d9ccc883efff3b5563.zip

fix: silence greps

Diffstat (limited to 'zuwu.zsh')
-rwxr-xr-xzuwu.zsh8
1 files changed, 4 insertions, 4 deletions
diff --git a/zuwu.zsh b/zuwu.zsh
index 14dce54..b845ad7 100755
--- a/zuwu.zsh
+++ b/zuwu.zsh
@@ -6,7 +6,7 @@ export _ZUWU_INSTALLED=1;
if [[ "$_ZUWU_DEBUG" == "1" ]]; then set -ax; fi
# Completion Handling
-if ! grep '# The following lines were added by compinstall' ~/.zshrc >/dev/null 2>/dev/null && ! grep 'compinit' ~/.zshrc; then
+if ! grep '# The following lines were added by compinstall' ~/.zshrc >/dev/null 2>/dev/null && ! grep 'compinit' ~/.zshrc >/dev/null 2>/dev/null; then
<<EOF >> ~/.zshrc
# Note: Do not remove the 'The following lines were...' comment!
# The following lines were added by compinstall
@@ -38,8 +38,8 @@ fi
noop() {}
# Ensure ~/.local/bin is in the PATH - note that this will "match" if something like `.*$HOME/.local/bin.*`, i don't care
-if ! grep "$HOME/.local/bin" <<< "$PATH"; then
- echo -n 'if ! grep "$HOME/.local/bin" <<< "$PATH"; then
+if ! grep "$HOME/.local/bin" <<< "$PATH" >/dev/null 2>/dev/null; then
+ echo -n 'if ! grep "$HOME/.local/bin" <<< "$PATH" >/dev/null 2>/dev/null; then
export PATH="$PATH:$HOME/.local/bin"
fi
' >> "$HOME/.zshenv"
@@ -130,7 +130,7 @@ reloadopt() {
reloadopt
# Fix $HOME path being entirely inlined in zsh completion shit (or any other string at the beginnig thereof)
-if grep "\"$HOME" "$HOME/.zshrc"; then
+if grep "\"$HOME" "$HOME/.zshrc" >/dev/null 2>/dev/null; then
sed -i "s|\"$HOME|\"\$HOME|g" "$HOME/.zshrc"
zstyle :compinstall filename "$HOME/.zshrc"
fi