summaryrefslogtreecommitdiff
path: root/printpath
blob: 1a1a60532090189f27db7ca267a962ccb86a9e22 (plain)
1
2
3
4
5
6
#!/bin/sh

echo "$PATH" | tr ':' '\n' | while IFS= read -r dir; do
    [ -d "$dir" ] || continue
    find "$dir" -maxdepth 1 -type f -perm -111 -printf '%f\n'
done | sort -u