figma.sh 862 Bytes
Newer Older
Vitaly Lipatov's avatar
Vitaly Lipatov committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
#!/bin/sh

PKGNAME=figma-linux
SUPPORTEDARCHES="x86_64"
VERSION="$2"
DESCRIPTION="Figma-linux - an unofficial Electron-based Figma desktop app for Linux"
URL="https://github.com/Figma-Linux/figma-linux"

. $(dirname $0)/common.sh

[ "$VERSION" = "*" ] && VERSION="[0-9]*"

pkgtype="$(epm print info -p)"

# https://github.com/Figma-Linux/figma-linux/releases/download/v0.10.0/figma-linux_0.10.0_linux_x86_64.rpm
# https://github.com/Figma-Linux/figma-linux/releases/download/v0.10.0/figma-linux_0.10.0_linux_amd64.deb

case "$pkgtype" in
    rpm)
        file="${PKGNAME}_${VERSION}_linux_x86_64.$pkgtype"
        ;;
    *)
        pkgtype="deb"
        file="${PKGNAME}_${VERSION}_linux_amd64.$pkgtype"
        ;;
esac

28
PKGURL=$(eget --list --latest https://github.com/Figma-Linux/figma-linux/releases "$file") || fatal "Can't get package URL"
Vitaly Lipatov's avatar
Vitaly Lipatov committed
29

30
install_pkgurl
Vitaly Lipatov's avatar
Vitaly Lipatov committed
31