You need to sign in or sign up before continuing.
alivecolors.sh 2.05 KB
Newer Older
1 2 3
#!/bin/sh

PKGNAME=alivecolors
4
SKIPREPACK=1
5 6 7 8 9
SUPPORTEDARCHES="x86_64"
DESCRIPTION="AliveColors from the official site"

case "$1" in
    "--remove")
10
        epm remove $(epm qp $PKGNAME-)
11 12 13 14 15 16 17 18 19 20 21
        epm repo remove akvis
        exit
        ;;
esac

. $(dirname $0)/common.sh

# Vendor instruction: https://alivecolors.com/ru/tutorial/howwork/install-linux.php

case $(epm print info -s) in
    alt)
22 23
        epm repo add "rpm https://akvis-alt.sfo2.cdn.digitaloceanspaces.com x86_64 akvis"
        epm repo add "rpm https://akvis-alt.sfo2.cdn.digitaloceanspaces.com noarch akvis"
24 25 26 27 28 29 30 31 32
        epm update
        epm install $PKGNAME
        echo "Run alivecolors:"
        echo "$ LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu alivecolors"
        exit
        ;;
    suse)
        # TODO: check and remove, the same as for dnf-part
        #a= rpm --import http://akvis.com/akvis.asc
33
        epm repo addkey https://akvis.com/akvis.asc
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
        # zypper ar -r https://akvis.com/akvis.repo akvis
        epm repo add https://akvis.com/akvis.repo
        # zypper ref
        epm update
        epm install $PKGNAME
        exit
        ;;
    *)
        fatal "Unsupported distro."
esac



case $(epm print info -g) in
    dnf-rpm|yum-rpm)
        #sudo rpm --import https://akvis.com/akvis.asc
50
        epm repo addkey https://akvis.com/akvis.asc
51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70
        #sudo wget -O /etc/yum.repos.d/akvis.repo https://akvis.com/akvis.repo
        epm repo add https://akvis.com/akvis.repo
        epm update
        epm install $PKGNAME
        exit
        ;;
    apt-dpkg)
        # TODO: add key support
        #sudo mkdir -p /usr/share/keyrings
        #eget -O - https://akvis.com/akvis.gpg | sudo tee /usr/share/keyrings/akvis.gpg >/dev/null
        #epm repo add 'deb [arch-=i386 signed-by=/usr/share/keyrings/akvis.gpg] https://akvis-deb.sfo2.cdn.digitaloceanspaces.com akvis non-free'
        epm repo add 'deb [arch-=i386] https://akvis-deb.sfo2.cdn.digitaloceanspaces.com akvis non-free'
        epm update
        epm install $PKGNAME
        exit
        ;;
    *)
        fatal "Unsupported packaging system"
esac