[arch-commits] Commit in (6 files)

Felix Yan felixonmars at archlinux.org
Sat Mar 7 14:29:46 UTC 2020


    Date: Saturday, March 7, 2020 @ 14:29:45
  Author: felixonmars
Revision: 591170

addpkg: clash 0.18.0-1

Added:
  clash/
  clash/repos/
  clash/trunk/
  clash/trunk/PKGBUILD
  clash/trunk/clash at .service
  clash/trunk/clash_user.service

--------------------+
 PKGBUILD           |   32 ++++++++++++++++++++++++++++++++
 clash at .service     |   12 ++++++++++++
 clash_user.service |   11 +++++++++++
 3 files changed, 55 insertions(+)

Added: clash/trunk/PKGBUILD
===================================================================
--- clash/trunk/PKGBUILD	                        (rev 0)
+++ clash/trunk/PKGBUILD	2020-03-07 14:29:45 UTC (rev 591170)
@@ -0,0 +1,32 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Ariel AxionL <i at axionl.me>
+# Contributor: Luke Yue <lukedyue at gmail.com>
+
+pkgname=clash
+pkgver=0.18.0
+pkgrel=1
+pkgdesc="A rule based proxy in Go"
+arch=('x86_64')
+url="https://github.com/Dreamacro/clash"
+license=('GPL3')
+makedepends=('go' 'git')
+depends=('glibc')
+source=("clash at .service"
+        "clash_user.service"
+        "${pkgname}-${pkgver}.tar.gz::https://github.com/Dreamacro/clash/archive/v${pkgver}.tar.gz")
+sha512sums=('e9e215e0a06d0d1072467342dd72e777725b94634714c5bd5fdee31f48897d9b8ab7e83830d836533d6862fa6ebfda56dbf138edd873140de61d8ccdf2a54572'
+            '338c3a5904623bec48c03b2ef8cf452979c229fc5b89b2e0447664b40cd6e29c83cae47a19145be76d3ee2f0b6a54184a0cff69b834ba6107b444caacc02decf'
+            'abfaebf269c3cf69fa82a7537dfe8b5b00ea332bdf70d4b3d3d8ec232b697b87e5450bd63d00b11c4785a8d1555b05aec47a8d0f7f7f69b2085946919fed3113')
+
+build() {
+    cd "${pkgname}-${pkgver}"
+    go build -ldflags "-extldflags ${LDFLAGS} -X github.com/Dreamacro/clash/constant.Version=${pkgver} -w -s" -mod=readonly
+}
+
+package() {
+    cd "${srcdir}/${pkgname}-${pkgver}"
+    install -Dm755 "clash" "${pkgdir}/usr/bin/clash"
+    install -Dm644 "LICENSE" "${pkgdir}/usr/share/licenses/clash/LICENSE"
+    install -Dm644 "${srcdir}/clash at .service" "${pkgdir}/usr/lib/systemd/system/clash at .service"
+    install -Dm644 "${srcdir}/clash_user.service" "${pkgdir}/usr/lib/systemd/user/clash.service"
+}

Added: clash/trunk/clash at .service
===================================================================
--- clash/trunk/clash at .service	                        (rev 0)
+++ clash/trunk/clash at .service	2020-03-07 14:29:45 UTC (rev 591170)
@@ -0,0 +1,12 @@
+[Unit]
+Description=A rule based proxy in Go for %i.
+After=network.target
+
+[Service]
+Type=simple
+User=%i
+Restart=on-abort
+ExecStart=/usr/bin/clash
+
+[Install]
+WantedBy=multi-user.target

Added: clash/trunk/clash_user.service
===================================================================
--- clash/trunk/clash_user.service	                        (rev 0)
+++ clash/trunk/clash_user.service	2020-03-07 14:29:45 UTC (rev 591170)
@@ -0,0 +1,11 @@
+[Unit]
+Description=A rule based proxy in Go.
+After=network.target
+
+[Service]
+Type=simple
+Restart=on-abort
+ExecStart=/usr/bin/clash
+
+[Install]
+WantedBy=default.target



More information about the arch-commits mailing list