From c0319652b7a57a703499fd5b7b0951667b4a3a85 Mon Sep 17 00:00:00 2001 From: Brian Corrigan Date: Fri, 8 Jun 2012 11:56:15 -0700 Subject: [PATCH] Allows alternate install locations, and repos --- README.md | 10 ++++++++++ utils/installer.sh | 4 ++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 806e572..8e0f4dd 100644 --- a/README.md +++ b/README.md @@ -34,6 +34,16 @@ https://github.com/bbatsov/prelude/raw/master/utils/installer.sh You can now power up your Emacs, sit back and enjoy Prelude. +There are two environment variables you can use to control the +source repository and the installation directory. For instance: + +`PRELUDE_URL="https://github.com/yourname/prelude.git" && + PRELUDE_INSTALL_DIR="$HOME/.emacs.d" && + curl -L +https://github.com/bbatsov/prelude/raw/master/utils/installer.sh +| sh` + + ## Would you like to know more? Check out the [Prelude's project page](http://batsov.com/prelude) for diff --git a/utils/installer.sh b/utils/installer.sh index 56c26c6..011261e 100755 --- a/utils/installer.sh +++ b/utils/installer.sh @@ -1,5 +1,5 @@ -PRELUDE_INSTALL_DIR="$HOME/.emacs.d" -PRELUDE_URL=https://github.com/bbatsov/prelude.git +[ -z "$PRELUDE_INSTALL_DIR" ] && PRELUDE_INSTALL_DIR="$HOME/.emacs.d" +[ -z "$PRELUDE_URL" ] && PRELUDE_URL=https://github.com/bbatsov/prelude.git if [ -d $PRELUDE_INSTALL_DIR/prelude ] then