debmaker/ressources/joplin/joplin
thomas b69d1ee47f Add gotify
optimize apt without recommends packages
add package dpkg fakeroot when needed
2022-02-20 23:33:43 +01:00

20 lines
525 B
Bash
Executable file

#!/bin/bash
STEP="envinit makedeb"
envinit() {
apt-get install -y wget ca-certificates fakeroot dpkg
}
makedeb(){
GIT_VERSION=$1
DEB_VERSION=$2
PATH_DEB=/tmp/dist/rootfs
wget https://github.com/laurent22/joplin/releases/download/v${GIT_VERSION}/Joplin-${GIT_VERSION}.AppImage -qO ${PATH_DEB}/usr/share/joplin/Joplin.AppImage
chmod +x ${PATH_DEB}/usr/share/joplin/Joplin.AppImage
sed -i "s/%VERSION%/$DEB_VERSION/" /tmp/dist/rootfs/DEBIAN/control
fakeroot dpkg-deb -Z gzip --build /tmp/dist/rootfs/ /tmp/dist/
}