packages/README.sh

12 lines
382 B
Bash
Executable File

#!/bin/sh
# print README.md until '# Component List'
grep -B9999 '# Packages' README.md
echo ''
echo '| package | description |'
echo '|-|-|'
find * -maxdepth 0 -type d | while read pkg; do
echo "| [$pkg]($pkg) | $(awk 'NR == 3 {print $0}' $pkg/README.md) |"
done
echo -e '\n> developers: run `echo "$(./README.sh)" > README.md` to regenerate this README.md after adding a pkg'