debmaker/ressources/babybuddy/debmaker
2023-07-30 22:08:46 +02:00

32 lines
788 B
Bash
Executable file

#!/bin/bash
VERSION=2.0.4
APP=babybuddy
DEPOT=https://github.com/babybuddy/babybuddy.git
GIT_VERSION=v${VERSION}
DEB_VERSION=${VERSION}-$(date +%Y%m%d%H%M)
DEBIAN_VERSION_CODENAME=bookworm
IMAGE_SIZE=6
PACKAGE_DEPENDENCY=""
main(){
base_package_upgrade
install_package_dependency
get_git_source
makedeb
}
makedeb(){
PATH_DEB=/tmp/src/rootfs
mkdir -p ${PATH_DEB}/etc/babybuddy/
mv /tmp/${APP}/babybuddy/settings/production.example.py ${PATH_DEB}/etc/babybuddy/production.py
mkdir -p ${PATH_DEB}/usr/share/
cp -fr /tmp/${APP}/ ${PATH_DEB}/usr/share/
ln -s /etc/babybuddy/production.py ${PATH_DEB}/usr/share/babybuddy/babybuddy/settings/production.py
sed -i "s/%VERSION%/$DEB_VERSION/" ${PATH_DEB}/DEBIAN/control
fakeroot dpkg-deb -Z gzip --build ${PATH_DEB} /tmp/dist
}