Skip to content

Instantly share code, notes, and snippets.

@2m
Created October 17, 2018 15:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 2m/01b8f96d46f887f39ef83648fb218a50 to your computer and use it in GitHub Desktop.
Save 2m/01b8f96d46f887f39ef83648fb218a50 to your computer and use it in GitHub Desktop.
From 6e138eaffb0064f4c74e6373449ee7cd6ee64031 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Martynas=20Mickevi=C4=8Dius?= <self@2m.lt>
Date: Wed, 17 Oct 2018 11:56:31 -0400
Subject: [PATCH] Prepend shebang
---
PKGBUILD | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git PKGBUILD PKGBUILD
index 45f3ae9..e82cb95 100644
--- PKGBUILD
+++ PKGBUILD
@@ -2,7 +2,7 @@
pkgname=ammonite
pkgver=1.2.1
-pkgrel=1
+pkgrel=2
pkgdesc="A cleanroom re-implementation of the Scala REPL from first principles. "
arch=('any')
url="https://github.com/lihaoyi/Ammonite"
@@ -16,8 +16,12 @@ sha256sums=('4e56e25400d7fe9bd35771e0db731a65b624eabe6433b29df4f506dc20f3dd24'
'90320c4bcccf8df57cc5d6f7b0b1778231ae87c64fe5405bae45af4ff9f87e8e')
install="${pkgname}.install"
+prepare() {
+ sed '1s;^;#!/usr/bin/env sh\n;' ammonite-repl-${pkgver} > ammonite-repl-${pkgver}.patched
+}
+
package() {
- install -Dm755 "ammonite-repl-${pkgver}" "${pkgdir}/usr/bin/amm"
+ install -Dm755 "ammonite-repl-${pkgver}.patched" "${pkgdir}/usr/bin/amm"
install -Dm644 'LICENSE' "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
--
2.19.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment