summaryrefslogtreecommitdiffstats
path: root/pearup
diff options
context:
space:
mode:
Diffstat (limited to 'pearup')
-rwxr-xr-xpearup8
1 files changed, 7 insertions, 1 deletions
diff --git a/pearup b/pearup
index 85c913f..b4a023c 100755
--- a/pearup
+++ b/pearup
@@ -5,7 +5,7 @@ rpmdate=$(LC_ALL="C" date +"%a %b %d %Y")
rpmdate=${rpmdate/ 0/ }
if [ $# -lt 2 ]; then
- echo "usage $0 old new [ spec ]"
+ echo "usage $0 old new [ spec ] [ oldsuffix newsuffix ]"
exit 1
fi
if [ -n "$3" ]; then
@@ -14,6 +14,12 @@ else
name=$(basename $PWD).spec
fi
+if [ ! -f $3 ]; then
+ echo "cannot read '$3' spec file"
+ echo "usage $0 old new [ spec ] [ oldsuffix newsuffix ]"
+ exit 1
+fi
+
oldver="$1"
newver="$2"
rpmver="$2"