galeb

Једноставна статичка дистрибуција заснована на musl-у
git clone https://git.sr.ht/~strahinja/galeb
Дневник | Датотеке | Референце | ПРОЧИТАЈМЕ | ЛИЦЕНЦА

impostors (546B)


      1 #!/bin/sh
      2 
      3 . ./lib/env.sh
      4 
      5 cols=''
      6 if [ -n "$1" ]; then
      7 	cols="-c $1"
      8 fi
      9 
     10 {
     11 	cd ${GR}
     12 	printf "Program\tStatic/Dynamic\tDirectory\n"
     13 	find bin sucks/bin -type f | \
     14 	while read -r file; do
     15 		type=$(file ${file})
     16 		printf "%s\t" ${file##*/}
     17 		case ${type} in
     18 			*static*)	printf "S\t";;
     19 			*dynamic*)	printf "D\t";;
     20 			*)		printf "\t";;
     21 		esac
     22 		printf "%s\n" ${file%/*}
     23 	done
     24 	cd - >/dev/null 2>&1
     25 } | awk '{
     26 	FS="\t"
     27 	if (NR==1 || ($2=="D" && $3=="bin") || ($2=="S" && $3=="sucks/bin"))
     28 		print;
     29 }' | table -d "$(printf '\t')" ${cols} | less -S