mirror of
https://github.com/gentoo-mirror/gentoo-zh.git
synced 2025-04-18 07:18:58 -04:00
net-misc/alist: new package, add 3.32.0
Signed-off-by: Yongxiang Liang <tanekliang@gmail.com>
This commit is contained in:
parent
cd42d33769
commit
8112886d47
3
net-misc/alist/Manifest
Normal file
3
net-misc/alist/Manifest
Normal file
@ -0,0 +1,3 @@
|
||||
DIST alist-3.32.0-deps.tar.xz 684901572 BLAKE2B 9e2413321e88d32d5bdb44207bfee78aab7e0c55a636b13f9d8cc74f936ff8da7240bde96f523c40b31f4204528f3837c83fb0b8bc727805f4e76a43f6deba6e SHA512 91635f7cedee1f38d2852fc7497cdaaa406d559bec6fb54c1b02bf55c9938edd63e2ec43d0312ed96aea98218e7612dc9c0cc77c65e242df3ff13fc137cef0e1
|
||||
DIST alist-3.32.0-dist.tar.gz 8484414 BLAKE2B bbdf5923dd631d1ea048b07e93acdfee10662beaf56b6d5da0819c28d7db026d9781989c6bf67e812271d61e3ae693f79ea748e236a177190b635f43b3ae2cc5 SHA512 612b1fec27a1d2888e446f70a0d0b198b02e170ab0022b5b09e260762351fe851ab7ee54576fcf6f2f30b18897a7bc1db20d6590f58bcd63a752c5a25b30d50a
|
||||
DIST alist-3.32.0.tar.gz 481257 BLAKE2B ccb550e97401e1c96e6cfbe4ec08bc9c4190fe0c25d6d987d3a870ed70af7d40257f327771647df488b5e6e32fbbb38a802d7881ea0664c7ad2011f72c46d356 SHA512 44d00f50f2510008ebab37b0c80d86c9055d9ec636379e4b0c5759f3a9f2a3d6fb71a65231c3c28d1c26a951061f9d88a53483f0bf28abfbddaced33555a361c
|
44
net-misc/alist/alist-3.32.0.ebuild
Normal file
44
net-misc/alist/alist-3.32.0.ebuild
Normal file
@ -0,0 +1,44 @@
|
||||
# Copyright 2024 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit go-module systemd
|
||||
GIT_COMMIT="ae69847"
|
||||
|
||||
DESCRIPTION="A file list/WebDAV program that supports multiple storages"
|
||||
HOMEPAGE="https://alist.nn.ci"
|
||||
SRC_URI="
|
||||
https://github.com/alist-org/alist/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz
|
||||
https://github.com/alist-org/alist-web/releases/download/${PV}/dist.tar.gz -> ${P}-dist.tar.gz
|
||||
https://github.com/liangyongxiang/gentoo-go-deps/releases/download/${P}/${P}-deps.tar.xz
|
||||
"
|
||||
|
||||
LICENSE="AGPL-3"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64"
|
||||
|
||||
QA_PRESTRIPPED="/usr/bin/${PN}"
|
||||
|
||||
src_prepare() {
|
||||
rm -rf public/dist || die
|
||||
mv "${WORKDIR}/dist public" || die
|
||||
default
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
local ldflags="\
|
||||
-X 'github.com/alist-org/alist/v3/internal/conf.BuiltAt=$(date +'%F %T %z')' \
|
||||
-X 'github.com/alist-org/alist/v3/internal/conf.GoVersion=$(go version | cut -d ' ' -f 3)' \
|
||||
-X 'github.com/alist-org/alist/v3/internal/conf.GitAuthor=\"Xhofe <i@nn.ci>\"' \
|
||||
-X 'github.com/alist-org/alist/v3/internal/conf.GitCommit=${GIT_COMMIT}' \
|
||||
-X 'github.com/alist-org/alist/v3/internal/conf.Version=${PV}' \
|
||||
-X 'github.com/alist-org/alist/v3/internal/conf.WebVersion=${PV}' \
|
||||
-w -s"
|
||||
ego build -o ${PN} -trimpath -ldflags "${ldflags}"
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin ${PN}
|
||||
systemd_dounit "${FILESDIR}/alist.service"
|
||||
}
|
14
net-misc/alist/files/alist.service
Normal file
14
net-misc/alist/files/alist.service
Normal file
@ -0,0 +1,14 @@
|
||||
[Unit]
|
||||
Description=alist
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=alist
|
||||
WorkingDirectory=/var/lib/alist
|
||||
ExecStart=/usr/bin/alist server --data /var/lib/alist
|
||||
Restart=on-failure
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
11
net-misc/alist/metadata.xml
Normal file
11
net-misc/alist/metadata.xml
Normal file
@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
|
||||
<pkgmetadata>
|
||||
<maintainer type="person">
|
||||
<email>tanekliang@gmail.com</email>
|
||||
<name>Yongxiang Liang</name>
|
||||
</maintainer>
|
||||
<upstream>
|
||||
<remote-id type="github">alist-org/alist</remote-id>
|
||||
</upstream>
|
||||
</pkgmetadata>
|
Loading…
x
Reference in New Issue
Block a user