From 57c386e182cbeb69d331ca88fe569d15a0bf2644 Mon Sep 17 00:00:00 2001 From: j4hangir Date: Tue, 10 Oct 2023 18:51:14 +0200 Subject: [PATCH 1/4] redefine mdfind() --- aliases.zsh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/aliases.zsh b/aliases.zsh index 76d881d..c99d427 100644 --- a/aliases.zsh +++ b/aliases.zsh @@ -52,6 +52,12 @@ elif [[ $os == 'freebsd' || $os == 'mac' ]]; then alias ls='\ls -G -lahtr' alias l.='\ls -Gd .* -Gtr' alias updatedb='sudo /usr/libexec/locate.updatedb' + + # j4hangir: redefine mdfind and remove UserQueryParser superfluous msgs + function mdfind() { + /usr/bin/mdfind $@ 2> >(grep --invert-match ' \[UserQueryParser\] ' >&2) + } + srch() { mdfind -name $@ } From 8b5bc22fe58e033f70c3036b87077d7fd7411430 Mon Sep 17 00:00:00 2001 From: j4hangir Date: Wed, 10 Jan 2024 21:41:52 +0100 Subject: [PATCH 2/4] add find_bundle_name for mac --- aliases.zsh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/aliases.zsh b/aliases.zsh index 2425257..6509d59 100644 --- a/aliases.zsh +++ b/aliases.zsh @@ -14,6 +14,7 @@ alias .....='cd ../../../../' alias .4='cd ../../../../' alias .5='cd ../../../../..' alias hick='history | ack -i' +#alias history='history | aul' alias pu='pushd' alias po='popd' @@ -81,6 +82,11 @@ cdl () { # fi #} + +function find_bundle_name() { + mdfind "kMDItemKind == 'Application'" | grep -i $1 | head -1 | xargs -I {} defaults read {}/Contents/Info CFBundleIdentifier | tee >(pbcopy) +} + opf () { if [[ $os == 'mac' ]]; then c="netstat -antvp tcp" From ab1d60c0f404c95804f965aaeb3dbb8097792093 Mon Sep 17 00:00:00 2001 From: j4hangir Date: Wed, 27 Mar 2024 20:10:56 +0100 Subject: [PATCH 3/4] auto execute .tmux.zsh when exists --- init.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/init.sh b/init.sh index 67d5786..2720e30 100755 --- a/init.sh +++ b/init.sh @@ -44,6 +44,9 @@ antigen apply #antigen use prezto source $DIR/.zshrc +if [ -f ~/.tmux.zsh ]; then + source ~/.tmux.zsh +fi # echo " _ _ __ _ _ __ From 1e1a1e0631651dfc018bbe6fa0d31ee8142a9963 Mon Sep 17 00:00:00 2001 From: j4hangir Date: Wed, 27 Mar 2024 20:13:13 +0100 Subject: [PATCH 4/4] revert --- init.sh | 4 ---- 1 file changed, 4 deletions(-) diff --git a/init.sh b/init.sh index 2720e30..bb5dd3e 100755 --- a/init.sh +++ b/init.sh @@ -44,10 +44,6 @@ antigen apply #antigen use prezto source $DIR/.zshrc -if [ -f ~/.tmux.zsh ]; then - source ~/.tmux.zsh -fi - # echo " _ _ __ _ _ __ # __/\__ _ __ (_) __ __ (_) / _| (_) ___ __| | _ \ \