pencil.sh 869 Bytes
Newer Older
1 2 3
#!/bin/sh

PKGNAME=Pencil
4
REPOPKGNAME=pencil
5
SUPPORTEDARCHES="x86_64 x86"
6
VERSION="$2"
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
DESCRIPTION="Pencil from the official site"
URL="https://pencil.evolus.vn/"

. $(dirname $0)/common.sh

arch=$(epm print info --distro-arch)
case $arch in
    x86_64|amd64)
        arch=$arch ;;
    i686|i386)
        arch=$arch ;;
    i586)
        arch=i686 ;;
    *)
        fatal "Unsupported arch $arch for $(epm print info -d)"
esac

# current links:
# https://pencil.evolus.vn/dl/V3.1.1.ga/Pencil-3.1.1.ga.x86_64.rpm
# https://pencil.evolus.vn/dl/V3.1.1.ga/Pencil-3.1.1.ga.i686.rpm
# https://pencil.evolus.vn/dl/V3.1.1.ga/Pencil_3.1.1.ga_amd64.deb
# https://pencil.evolus.vn/dl/V3.1.1.ga/Pencil_3.1.1.ga_i386.deb

30
mask="$(epm print constructname $PKGNAME "$VERSION.ga" $arch)"
31

32
PKGURL="$(eget --list --latest https://pencil.evolus.vn/Downloads.html "$mask")"
33 34

install_pkgurl