status.sh: update with data and extra commit info

This commit is contained in:
pedro 2024-02-23 11:07:23 +01:00
parent 650db20086
commit dc61c0d753
1 changed files with 3 additions and 2 deletions

View File

@ -20,10 +20,11 @@ main() {
echo "- ${i}"
for d in ${dirs}; do
cd ${d}
commit="$(git log --pretty=format:'%H' -n 1)"
# src https://ma.ttias.be/pretty-git-log-in-one-line/
commit_info="$(git log --pretty=format:'[%ci] %an: %s (%h)' -n 1)"
cd - >/dev/null
d_name="$(basename "${d}")"
echo " - ${d_name}, commit: ${commit}"
echo " - ${d_name}, commit: ${commit_info}"
done
done
}