summaryrefslogtreecommitdiff
path: root/asdf-vm
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2021-12-20 08:20:07 +0100
committerErich Eckner <git@eckner.net>2021-12-20 08:20:07 +0100
commit4134fafb872a4ccbd89ebdf1adc7d3cd69da1684 (patch)
tree1f49ad644eb6e841b2128bca364cc38805dd126d /asdf-vm
parentcd68d968da307964113c2acd665a099588cee1c1 (diff)
downloadarchlinuxewe-4134fafb872a4ccbd89ebdf1adc7d3cd69da1684.tar.xz
asdf-vm new
Diffstat (limited to 'asdf-vm')
-rw-r--r--asdf-vm/PKGBUILD61
-rw-r--r--asdf-vm/asdf-vm.install11
2 files changed, 72 insertions, 0 deletions
diff --git a/asdf-vm/PKGBUILD b/asdf-vm/PKGBUILD
new file mode 100644
index 000000000..85d23a6b7
--- /dev/null
+++ b/asdf-vm/PKGBUILD
@@ -0,0 +1,61 @@
+# Maintainer: Erich Eckner <arch at eckner dot net>
+# Contributor: Alec Mev <alec@mev.earth>
+
+pkgname=asdf-vm
+pkgver=0.8.1
+pkgrel=1
+pkgdesc='Extendable version manager with support for Ruby, Node.js, Elixir, Erlang & more'
+arch=('any')
+url='https://asdf-vm.com'
+license=('MIT')
+depends=(
+ 'autoconf'
+ 'automake'
+ 'libffi'
+ 'libtool'
+ 'libxslt'
+ 'libyaml'
+ 'ncurses'
+ 'openssl'
+ 'readline'
+ 'unixodbc'
+)
+optdepends=(
+ 'bash-completion: For completions to work in Bash'
+ 'unzip: Needed by some plugins, like Elixir'
+)
+install=asdf-vm.install
+source=("${pkgname}-${pkgver}.tar.gz::https://github.com/asdf-vm/asdf/archive/v${pkgver}.tar.gz")
+sha256sums=('6ca280287dcb687ec12f0c37e4e193de390cdab68f2b2a0e271e3a4f1e20bd2e')
+
+package() {
+ cd "asdf-${pkgver}"
+
+ local dst="${pkgdir}/opt/${pkgname}"
+ mkdir -p "${dst}"
+
+ cp -r bin "${dst}"
+ cp -r lib "${dst}"
+ cp asdf.fish "${dst}"
+ cp asdf.sh "${dst}"
+ cp defaults "${dst}"
+ cp help.txt "${dst}"
+ cp LICENSE "${dst}"
+ cp VERSION "${dst}"
+
+ local usrshare="${pkgdir}/usr/share"
+ local docdir="${usrshare}/doc/${pkgname}"
+ mkdir -p "${docdir}"
+
+ cp docs/[^_]*.md "${docdir}"
+ cp help.txt "${docdir}"
+ cp README.md "${docdir}"
+
+ install -Dm644 -t "${usrshare}/licenses/${pkgname}/" LICENSE
+
+ cd completions
+
+ install -Dm644 asdf.bash "${usrshare}/bash-completion/completions/asdf"
+ install -Dm644 asdf.fish "${usrshare}/fish/vendor_completions.d/asdf.fish"
+ install -Dm644 _asdf "${usrshare}/zsh/site-functions/_asdf"
+}
diff --git a/asdf-vm/asdf-vm.install b/asdf-vm/asdf-vm.install
new file mode 100644
index 000000000..facc34dd7
--- /dev/null
+++ b/asdf-vm/asdf-vm.install
@@ -0,0 +1,11 @@
+post_install() {
+ cat <<EOF
+
+Follow the official instructions [1] to make asdf-vm work, replacing
+"\$HOME/.asdf" with "/opt/asdf-vm". The completions are already installed, just
+make sure your shell is configured to use them.
+
+[1] https://asdf-vm.com/#/core-manage-asdf?id=add-to-your-shell
+
+EOF
+}