2 # Convert git log to GNU-style ChangeLog file.
4 if test -d ".git"; then
6 --format="commit %H%nAuthor: %an %ae%nDate: %ad%n %s%n" $@ | \
7 sed -e '/^commit.*$/d' | \
8 awk '/^Author/ {sub(/\\$/,""); getline t; print t $0; next}; 1' | \
9 sed -e 's/Author: //g' | \
10 sed -e 's/^Date: \(.*\)/\* \1/g' | \
11 sed -e 's/\+0000//' -e 's/[0-9]\+\:[0-9]\+\:[0-9]\+ //' | \
12 sed -e 's/^\(.*\) \(\)\t\(.*\)/\3 \1 \2/g' | \
13 sed -e 's/^ /- /' -e 's/^$//'
16 echo "No git repository present."