| 1 |
#!/bin/sh |
| 2 |
# Copyright: © 2012 Enrico Tassi <[email protected]> |
| 3 |
# License: MIT |
| 4 |
|
| 5 |
if [ -z "$1" -o "$1" = "-h" -o "$1" = "--help" ]; then |
| 6 |
echo Give as a unique argument the name of the source package |
| 7 |
echo that will be the name of the root directory of the package. |
| 8 |
exit 1 |
| 9 |
fi |
| 10 |
|
| 11 |
PKG=$1 |
| 12 |
|
| 13 |
mkdir $PKG/ |
| 14 |
cd $PKG |
| 15 |
git init |
| 16 |
git remote add origin [email protected]:lua-team/$PKG.git |
| 17 |
[ ! -z "$DEBFULLNAME" ] && git config user.name "$DEBFULLNAME" |
| 18 |
[ ! -z "$DEBEMAIL" ] && git config user.email "<$DEBEMAIL>" |
| 19 |
cd .. |
| 20 |
mkdir $PKG/debian |
| 21 |
mkdir $PKG/debian/patches |
| 22 |
mkdir $PKG/debian/source |
| 23 |
mkdir $PKG/debian/tests |
| 24 |
|
| 25 |
echo '3.0 (quilt)' > $PKG/debian/source/format |
| 26 |
touch $PKG/debian/patches/series |
| 27 |
cp /usr/share/dh-lua/template/dh-lua.conf $PKG/debian/ |
| 28 |
cp /usr/share/dh-lua/template/rules $PKG/debian/ |
| 29 |
cp /usr/share/dh-lua/template/copyright $PKG/debian/ |
| 30 |
cp /usr/share/dh-lua/template/control $PKG/debian/ |
| 31 |
cp /usr/share/dh-lua/template/compat $PKG/debian/ |
| 32 |
cp /usr/share/dh-lua/template/tests.control $PKG/debian/tests/control |
| 33 |
cp /usr/share/dh-lua/template/tests.dh-lua-tests $PKG/debian/tests/dh-lua-tests |
| 34 |
chmod a+x $PKG/debian/rules |
| 35 |
cd $PKG |
| 36 |
git add debian/ |
| 37 |
cd .. |