Skip to content

Instantly share code, notes, and snippets.

@lazyfrosch
Created April 29, 2014 18:33
Show Gist options
  • Select an option

  • Save lazyfrosch/11408349 to your computer and use it in GitHub Desktop.

Select an option

Save lazyfrosch/11408349 to your computer and use it in GitHub Desktop.
release skript for launchpad
#!/bin/bash
set -e
makesource() {
version="$1"
shift
dist="$1"
shift
echo "Building source package for $dist ..."
rm -f debian/changelog.dch
dch --local "~ppa$version+" --distribution "$dist" -- "Release for Launchpad - $dist"
dpkg-parsechangelog
dpkg-buildpackage -S -uc -us "$@"
debsign ../*"~ppa$version+1_source.changes"
cp debian/changelog.lptool debian/changelog
}
echo "We start releasing the package for launchpad..."
echo
dpkg-parsechangelog
echo
echo "Start based on this changelog? [Y/n] "
ANSWER=""
read ANSWER
case "$ANSWER" in
n|N|no|NO)
echo "break..."
exit 1
;;
esac
# backup changelog
cp debian/changelog debian/changelog.lptool
makesource 1404 trusty -sa "$@"
makesource 1310 saucy "$@"
makesource 1210 quantal "$@"
makesource 1204 precise "$@"
makesource 1004 lucid "$@"
rm debian/changelog.lptool
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment