File: updcl

package info (click to toggle)
gaphor 0.13.0-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 3,692 kB
  • ctags: 2,971
  • sloc: python: 19,981; xml: 247; makefile: 54; sh: 40
file content (36 lines) | stat: -rwxr-xr-x 757 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#!/bin/sh
#
# This is a small utility that updates the ChangeLog based on the svn status.
#
# Vi is started and the change content is merged at the top of the file.
#

TMPFILE="/tmp/ChangeLogEntry_$$"

{
  echo "`date '+%Y-%m-%d'`  `cat .developer`"
  echo "" 

  svn status | sort | \
  while read O FILE; do
    case "$O" in
     A)  echo $FILE | if read H F; then
           test -z "$F" \
             && echo "        * $FILE: New file." \
             || echo "        * $F: Moved from "
         fi
         ;;
     D)  echo "        * $FILE: Removed."
         ;;
     M)  echo "        * $FILE:"
         ;;
     ?)  # pass
         ;;
     X)  # external repository
         ;;
    esac
  done
  echo ""
} > $TMPFILE

vi -c "r $TMPFILE" ChangeLog