Procházet zdrojové kódy

To simplify and repair date/version validation.

git-svn-id: https://tufte-latex.googlecode.com/svn/trunk@157 516e2f36-ce3a-0410-bea4-1d4a03f5df72
master
Bil Kleb před 15 roky
rodič
revize
ccc69dae18
1 změnil soubory, kde provedl 7 přidání a 13 odebrání
  1. +7
    -13
      release

+ 7
- 13
release Zobrazit soubor

@@ -1,6 +1,7 @@
#! /bin/bash

# shell options: -o = on, +o = off
# Shell options: -o = on, +o = off

set -o errexit # exit on first error
set -o nounset # report unset variables
set +o xtrace # show commands
@@ -24,18 +25,11 @@ fi

# TODO: instead of all this checking, just sed values into the appropriate files

for class_file in $CLASS_FILES ; do
if ! grep -q $VERSION $class_file -o ! grep -q $DATE $class_file ; then
echo "Error: '$VERSION' and '$DATE' do not match that in $class_file:"
grep -H ProvidesClass $class_file
exit 1
fi
done

for aux_file in $DEF_FILES ; do
if ! grep -q $VERSION $aux_file -o ! grep -q $DATE $aux_file ; then
echo "Error: '$VERSION' and '$DATE' do not match that in $aux_file"
grep -H ProvidesFile $aux_file
DATE_VERSION="$DATE $VERSION"
for file in $CLASS_FILES $DEF_FILES ; do
if ! grep -q $DATE_VERSION $file ; then
echo "Error: $file does not contain '$DATE_VERSION':"
egrep 'Provides(Class|File)' $file
exit 1
fi
done


Načítá se…
Zrušit
Uložit