summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorKlaus Alexander Seistrup2023-10-26 21:54:44 +0200
committerKlaus Alexander Seistrup2023-10-26 21:54:44 +0200
commit8f81cc00047e6c7998e2d27ec68d8beaa4d5015a (patch)
treef5a9abc2d62da9aea0571843387fbb4b3dbdaba1
parentedbe7eea406b503a2617eb1204e5a2249d29aade (diff)
downloadaur-8f81cc00047e6c7998e2d27ec68d8beaa4d5015a.tar.gz
Let's just use the simplest script possible
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD4
-rw-r--r--hx.sh14
3 files changed, 5 insertions, 17 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 017f25707a70..13da06c62b83 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = usrbinhx
pkgdesc = Provide /usr/bin/hx for the helix editor
pkgver = 2023.10.26
- pkgrel = 1
+ pkgrel = 2
url = https://codeberg.org/kas/gists
arch = any
license = AGPL3
@@ -10,6 +10,6 @@ pkgbase = usrbinhx
conflicts = hex
conflicts = helixbinhx
source = hx.sh
- sha256sums = 184cdaf013c0b3ac2fe4b95842f8f2ff97ae2fbe38e36e363badc419f9eaffa0
+ sha256sums = bc36799721ea4d0c3e1723f02b2b426c345bb180affebc72a529cd3a811f7f9c
pkgname = usrbinhx
diff --git a/PKGBUILD b/PKGBUILD
index 5386b00a0a37..20b899d8defb 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,7 +3,7 @@
pkgname='usrbinhx'
pkgver='2023.10.26'
-pkgrel=1
+pkgrel=2
pkgdesc='Provide /usr/bin/hx for the helix editor'
arch=('any')
url='https://codeberg.org/kas/gists'
@@ -11,7 +11,7 @@ license=('AGPL3')
conflicts=('hex' 'helixbinhx')
depends=('helix' 'sh')
source=('hx.sh')
-sha256sums=('184cdaf013c0b3ac2fe4b95842f8f2ff97ae2fbe38e36e363badc419f9eaffa0')
+sha256sums=('bc36799721ea4d0c3e1723f02b2b426c345bb180affebc72a529cd3a811f7f9c')
package() {
install -Dm0755 'hx.sh' "$pkgdir/usr/bin/hx"
diff --git a/hx.sh b/hx.sh
index b228098d34d8..cdaaf273a527 100644
--- a/hx.sh
+++ b/hx.sh
@@ -1,23 +1,11 @@
#!/bin/sh
-ME="${0##*/}"
-
# Copyright © 2022 Klaus Alexander Seistrup <klaus@seistrup.dk>
# Licensed under the GNU Affero General Public License v3+.
#
# Updated: 2023-10-26
-die() {
- printf '%s: %s\n' "$ME" "$*" >&2
- exit 1
-}
-
-export HELIX_DEFAULT_RUNTIME='/usr/lib/helix/runtime'
-
-export HELIX_HX='/usr/lib/helix/hx'
-test -x "$HELIX_HX" || die 'cannot find helix:' "$HELIX_HX"
-
-exec "$HELIX_HX" "$@"
+exec helix "$@"
exit 127
# eof