From ed70f3c2ffa92a72da29f7aa2020cb175e1801cf Mon Sep 17 00:00:00 2001 From: Zhao Zuohong Date: Tue, 7 Mar 2023 11:30:10 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=93=A6=20Package=20for=20Arch=20and=20Fed?= =?UTF-8?q?ora?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- launch.sh | 3 --- packaging/archlinux/.fpm | 16 ++++++++++++++++ packaging/archlinux/launch.sh | 3 +++ packaging/archlinux/package.sh | 10 ++++++++++ .fpm => packaging/fedora37/.fpm | 7 ++++++- packaging/fedora37/launch.sh | 3 +++ packaging/fedora37/package.sh | 10 ++++++++++ 7 files changed, 48 insertions(+), 4 deletions(-) delete mode 100755 launch.sh create mode 100644 packaging/archlinux/.fpm create mode 100755 packaging/archlinux/launch.sh create mode 100755 packaging/archlinux/package.sh rename .fpm => packaging/fedora37/.fpm (60%) create mode 100755 packaging/fedora37/launch.sh create mode 100755 packaging/fedora37/package.sh diff --git a/launch.sh b/launch.sh deleted file mode 100755 index 639d6c5..0000000 --- a/launch.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash - -/opt/badl/venv/bin/python -m badl diff --git a/packaging/archlinux/.fpm b/packaging/archlinux/.fpm new file mode 100644 index 0000000..536b192 --- /dev/null +++ b/packaging/archlinux/.fpm @@ -0,0 +1,16 @@ +-s dir +-t pacman +-p badl-0.1.0-any.pkg.tar.zst +-f +--name badl +--version 0.1.0 +--architecture all +--license gpl3 +--description "BiliBili Audio Downloader" +--url "https://git.zhaozuohong.vip/zhao/badl" +--maintainer "Zhao Zuohong " +--directories /opt/badl +--depends python-gobject --depends gtk3 --depends webkit2gtk + +venv/lib/python3.10/site-packages=/opt/badl/ +launch.sh=/usr/bin/badl diff --git a/packaging/archlinux/launch.sh b/packaging/archlinux/launch.sh new file mode 100755 index 0000000..8235606 --- /dev/null +++ b/packaging/archlinux/launch.sh @@ -0,0 +1,3 @@ +#!/bin/bash +cd /opt/badl/site-packages +/usr/bin/python3 -m badl diff --git a/packaging/archlinux/package.sh b/packaging/archlinux/package.sh new file mode 100755 index 0000000..dfb35ce --- /dev/null +++ b/packaging/archlinux/package.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +rm -fr venv +python3 -m venv venv +source venv/bin/activate +cd ../.. +pip install . +deactivate +cd packaging/archlinux +fpm diff --git a/.fpm b/packaging/fedora37/.fpm similarity index 60% rename from .fpm rename to packaging/fedora37/.fpm index 710b6c0..3e2af58 100644 --- a/.fpm +++ b/packaging/fedora37/.fpm @@ -1,4 +1,7 @@ -s dir +-t rpm +-p badl-0.1.0-any.rpm +-f --name badl --version 0.1.0 --architecture all @@ -6,6 +9,8 @@ --description "BiliBili Audio Downloader" --url "https://git.zhaozuohong.vip/zhao/badl" --maintainer "Zhao Zuohong " +--directories /opt/badl +--depends python3-gobject --depends webkit2gtk4.0 -venv=/opt/badl +venv/lib/python3.11/site-packages=/opt/badl/ launch.sh=/usr/bin/badl diff --git a/packaging/fedora37/launch.sh b/packaging/fedora37/launch.sh new file mode 100755 index 0000000..8235606 --- /dev/null +++ b/packaging/fedora37/launch.sh @@ -0,0 +1,3 @@ +#!/bin/bash +cd /opt/badl/site-packages +/usr/bin/python3 -m badl diff --git a/packaging/fedora37/package.sh b/packaging/fedora37/package.sh new file mode 100755 index 0000000..f7cfa30 --- /dev/null +++ b/packaging/fedora37/package.sh @@ -0,0 +1,10 @@ +#!/bin/bash + +rm -fr venv +python3 -m venv venv +source venv/bin/activate +cd ../.. +pip install . +deactivate +cd packaging/fedora37 +fpm