forked from ohmyzsh/ohmyzsh
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request ohmyzsh#4956 from RobLoach/asdf
Add asdf version manager plugin
- Loading branch information
Showing
2 changed files
with
34 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
## asdf | ||
|
||
**Maintainer:** [@RobLoach](https://github.com/RobLoach) | ||
|
||
Adds integration with [asdf](https://github.com/asdf-vm/asdf), the extendable version manager, with support for Ruby, Node.js, Elixir, Erlang and more. | ||
|
||
### Installation | ||
|
||
1. Enable the plugin by adding it to your `plugins` definition in `~/.zshrc`. | ||
|
||
``` | ||
plugins=(asdf) | ||
``` | ||
|
||
2. [Install asdf](https://github.com/asdf-vm/asdf#setup) by running the following: | ||
``` | ||
git clone https://github.com/asdf-vm/asdf.git ~/.asdf | ||
``` | ||
|
||
### Usage | ||
|
||
See the [asdf usage documentation](https://github.com/asdf-vm/asdf#usage) for information on how to use asdf: | ||
|
||
``` | ||
asdf plugin-add nodejs git@github.com:asdf-vm/asdf-nodejs.git | ||
asdf install nodejs 5.9.1 | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Find where asdf should be installed. | ||
ASDF_DIR="${ASDF_DIR:-$HOME/.asdf}" | ||
|
||
# Load asdf, if found. | ||
if [ -f $ASDF_DIR/asdf.sh ]; then | ||
. $ASDF_DIR/asdf.sh | ||
fi |