don't error out if there aren't any bz2 files anymore
[freeside.git] / bin / freeside-debian-releases.sh
index 7b95bb6..84d4e92 100755 (executable)
@@ -12,7 +12,7 @@ fi
 
 DATE=`date +"%Y%m%d"`
 DIR="/home/autobuild/packages/staging/freeside$FS_VERSION/$FS_REPO"
-TARGET="/home/jeremyd/public_html/freeside$FS_VERSION-$DISTRO-$FS_REPO"
+TARGET="/home/autobuild/public_html/freeside$FS_VERSION-$DISTRO-$FS_REPO"
 
 if [ ! -d "$DIR" -a -d $TARGET ]; then
 
@@ -42,7 +42,14 @@ pdebuild --pbuilderroot sudo --debbuildopts "-b -rfakeroot -uc -us" --buildresul
 
 #--buildresult gets the file where it needs to be, may need to clean up DIR
 
-cd $DIR; rm -f freeside_*
-cd $TARGET; rm -f *.gz
-
-$TARGET/APT
+cd $DIR && rm -f freeside_*
+cd $TARGET && rm -f *.gz
+
+apt-ftparchive -qq packages ./ >Packages
+gzip -c Packages >Packages.gz
+#bzip2 -c Packages >Packagez.bz2
+apt-ftparchive -qq sources ./ >Sources
+gzip -c Sources >Sources.gz
+#bzip2 -c Sources >Sources.bz2
+rm *bz2 || true
+apt-ftparchive -qq release ./ >Release