From fcf6b6c3eca77e9b7240a3fb1872dcffa38b8e29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20=27Necoro=27=20Neumann?= Date: Wed, 15 Apr 2020 23:27:20 +0200 Subject: Simplify check_libs --- .zsh/zshfunctions | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.zsh/zshfunctions b/.zsh/zshfunctions index 8f8b0c8..9c62e30 100644 --- a/.zsh/zshfunctions +++ b/.zsh/zshfunctions @@ -31,18 +31,14 @@ zman() { check_libs() { - local pmapc=" -[Fields Display] -Mapping" - local libs found=0 for i in $(ps -A -o 'pid='); do - libs=$(pmap -q -C<(<<<$pmapc) $i | + libs=$(pmap -q $i | grep '(deleted)' | grep -v '\\|\[aio\]\|SYSV0\|\' | tr -s ' ' | - cut -d' ' -f2 | + cut -d' ' -f4 | sort -u) if [[ -n $libs ]]; then -- cgit v1.2.3