svnup.sh
author rubidium
Mon, 03 Nov 2008 23:42:07 +0000
changeset 10318 d436fee569bf
parent 1583 7617a49e78e8
permissions -rwxr-xr-x
(svn r14563) -Fix [FS#2395]: in the case that an industry NewGRF, a shared TTDPatch and
OpenTTD feature with it's origin in TTDPatch to replace/add/change vehicles
(including e.g. maximum speed, graphics and introduction year), stations,
bridges, industries, town houses or any other graphics used by either
TTDPatch or OpenTTD, would tell that building an industry is okay, which
is queried using a so-called callback that allows the NewGRF author to
test all kinds of information about the neighbourhood where the industry
might get build, it would corrupt, i.e. overwrite with invalid data, the
structure that is used to build up an error message. This then might result
in trying to resolve an invalid StringID, an internal numeric representation
of all translateable strings, which would in it's turn trigger a safety
check that is added to ensure invalid StringIDs are never resolved.
#!/bin/sh
# This script updates the svn source and displays log changes
# This is only useful for users of CLI based SVN clients
# Written by Bjarni

[ "$PAGER" ] || PAGER=less


(

# reads what version you have now
Base=`svn info | grep "Revision" | xargs -n 1 | tail -n 1`

# updates the source
svn update > svn.log
cat svn.log

# if the revision number changed
if [ "$Base" -ne "`svn info | grep "Revision" | xargs -n 1 | tail -n 1`" ]; then
# displays the log changes
svn log -v -r HEAD:$(($Base + 1))
fi

# displays merged files
cat svn.log|grep "^G"
cat svn.log|grep "^C"

) | $PAGER