summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Weidenbaum2015-06-09 11:41:58 -0700
committerAndy Weidenbaum2015-06-09 11:41:58 -0700
commit6489e5d94eb000da385f97465e1e1d9a63830fc3 (patch)
treec6ea5d7334eee53d91cf74b0e737c9addeaa9150
downloadaur-6489e5d94eb000da385f97465e1e1d9a63830fc3.tar.gz
Initial import
-rw-r--r--.SRCINFO17
-rw-r--r--PKGBUILD45
-rw-r--r--exenv.install28
3 files changed, 90 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..dad3fa3998f9
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,17 @@
+pkgbase = exenv-git
+ pkgdesc = Elixir version management tool
+ pkgver = 20140615
+ pkgrel = 1
+ url = https://github.com/mururu/exenv
+ install = exenv.install
+ arch = any
+ license = MIT
+ makedepends = git
+ optdepends = elixir-build: compile and install different versions of Elixir
+ provides = exenv
+ conflicts = exenv
+ source = git+https://github.com/mururu/exenv
+ sha256sums = SKIP
+
+pkgname = exenv-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..97eb5c47973c
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,45 @@
+# Maintainer: Andy Weidenbaum <archbaum@gmail.com>
+
+pkgname=exenv-git
+pkgver=20140615
+pkgrel=1
+pkgdesc="Elixir version management tool"
+arch=('any')
+makedepends=('git')
+optdepends=('elixir-build: compile and install different versions of Elixir')
+url="https://github.com/mururu/exenv"
+license=('MIT')
+source=(git+https://github.com/mururu/exenv)
+sha256sums=('SKIP')
+provides=('exenv')
+conflicts=('exenv')
+install=exenv.install
+
+pkgver() {
+ cd ${pkgname%-git}
+ git log -1 --format="%cd" --date=short | sed "s|-||g"
+}
+
+package() {
+ cd ${pkgname%-git}
+
+ msg 'Installing license...'
+ install -Dm 644 LICENSE "$pkgdir/usr/share/licenses/${pkgname%-git}/LICENSE"
+
+ msg 'Installing documentation...'
+ install -Dm 644 README.md "$pkgdir/usr/share/doc/${pkgname%-git}/README.md"
+
+ msg 'Installing autocompletion...'
+ install -Dm 644 completions/exenv.bash "$pkgdir/usr/share/bash-completion/completions/exenv"
+ install -Dm 644 completions/exenv.zsh "$pkgdir/usr/share/zsh/site-functions/_exenv"
+
+ msg 'Installing executables...'
+ install -Dm 755 "bin/elixir-local-exec" "$pkgdir/usr/bin/elixir-local-exec"
+ for _bin in `find libexec -mindepth 1 -maxdepth 1 -type f -printf '%f\n'`; do
+ install -Dm 755 libexec/$_bin "$pkgdir/usr/bin/$_bin"
+ done
+
+ msg 'Cleaning up pkgdir...'
+ find "$pkgdir" -type d -name .git -exec rm -r '{}' +
+ find "$pkgdir" -type f -name .gitignore -exec rm -r '{}' +
+}
diff --git a/exenv.install b/exenv.install
new file mode 100644
index 000000000000..65d3191572b5
--- /dev/null
+++ b/exenv.install
@@ -0,0 +1,28 @@
+post_install() {
+ printf "%b\n" "$xnv"
+}
+
+post_upgrade() {
+ post_install
+}
+
+read -d '' xnv <<'EOF'
+exenv
+=====
+
+All exenv binaries, and autocompletion for bash and zsh have been
+installed.
+
+The only requirement for exenv to function properly is to add
+~/.exenv/shims to your PATH:
+
+ $ echo 'PATH=$HOME/.exenv/shims:$PATH' >> ~/.bashrc
+
+zsh note: Modify your ~/.zshrc file instead of ~/.bashrc
+
+For a kitchen sink configuration, add `exenv init` to your shell:
+
+ $ echo 'eval "$(exenv init -)"' >> ~/.bash_profile
+
+zsh note: Modify your ~/.zshenv file instead of ~/.bash_profile
+EOF