Brennan Fee
4cb89b152c
Fix another spot for plugin-name env var lookup
...
After fixing #319 I wondered if there were any other spots where the same/similar bug existed. I found one other location at line 126 in utils.sh.
2018-05-31 10:46:04 -05:00
Brennan Fee
67bc9539d1
Fix for #319
...
Fixed #319 by forcing all dashes to underscores in the plugin name.
Shell variables don't allow dash.
2018-05-30 20:02:23 -05:00
Melissa Xie
f79dda865a
Include plugin name in error message if plugin doesn't exist
...
Previously, if we ran a command like `asdf install` and we encountered a
plugin that didn't exist, asdf produces an error saying "No such
plugin". Without knowing which plugin it could be referring too, we'd
have to manually go through each plugin in `.tool-versions` to find the
culprit.
With this commit, we'll now also include the plugin name as part of the
messaging for easier debugging.
2018-04-30 12:49:40 -04:00
james.bunch
d62fa098c1
AZDF -> ASDF environment variable name spelling
...
change all instances of `AZDF` to read `ASDF` instead, to bring the
variable names in line with the project name
2018-02-27 11:56:04 -08:00
AJ Foster
eb5e5b780c
Refactor "no version set" message to utilities
2018-02-25 18:33:42 -05:00
AJ Foster
24a7190505
Specify when a version is set via environment variable
2018-02-25 01:11:16 -05:00
Trevor Brown
ed3a029e86
Merge branch 'master' into env-config-file-location
2018-02-11 17:31:17 -05:00
Trevor Brown
ee082dc6ee
Address warnings reported by new version of shellcheck.
2018-02-11 15:04:05 -05:00
Mark Villacampa
77ce346578
grep for plugin_name from begining of line
2017-12-15 22:36:24 +01:00
Daniel Perez
080c88d376
Revert "Fix edge case when looking for .asdf-version"
...
This reverts commit a44ec2779a
.
2017-10-27 14:25:29 +09:00
Daniel Perez
a44ec2779a
Fix edge case when looking for .asdf-version
...
cwd can potentially be a symlink, which breaks asdf logic.
The following command will fail to resolve the path correctly:
env - PWD=/proc/self/cwd PATH=$HOME/.asdf/shims:/bin ruby --version
This first resolves the real path of cwd before continuing to search
for a .tool-versions file
2017-10-25 19:51:13 +09:00
Shunsuke Kirino
9ba0a5cc2d
Replace ref-
prefix in output of list command with ref:
2017-10-23 11:23:51 +09:00
DustinChaloupka
320835ba7e
Declare and assign variable separately
2017-10-10 13:31:15 -05:00
DustinChaloupka
05a7446619
Add installing from a parent directory's .tool-versions
2017-10-10 12:02:42 -05:00
Jonathan Knapp
85550c8c0c
Remove extra, unnecessary quoting
2017-10-02 09:51:07 -04:00
Jonathan Knapp
20b70bccc7
Remove shebangs from lib files and pass bash dialect to shellcheck
2017-10-01 11:34:35 -04:00
Jonathan Knapp
33d7d9c26c
Merge remote-tracking branch 'source/master' into origin/shellcheck
2017-10-01 09:15:22 -04:00
Hugo Peixoto
15e59686c4
Add support for $ASDF_DEFAULT_TOOL_VERSIONS_FILENAME
...
Instead of just looking in $HOME/.tool-versions, allow the default
tool-versions file location to be specified through the variable
$ASDF_TOOL_VERSIONS.
2017-09-25 14:26:14 +01:00
Trevor Brown
4da62b16c8
Move hardcoded version to VERSION file in repo root.
2017-09-12 18:48:00 -04:00
Trevor Brown
663ebb9a2f
Move asdf_repository_url function to top of utils.sh.
2017-09-06 21:37:08 -04:00
Victor Borja
e814d58da3
Shellcheck all commands
2017-09-04 12:04:56 -05:00
Jonathan Knapp
9d6ddb71d5
Fix linter errors
2017-09-04 10:12:45 -04:00
Jonathan Knapp
f75e988363
Fix another linter error that did not trigger on osx
2017-09-04 10:11:06 -04:00
Jonathan Knapp
91d52b99cb
Run shellcheck on lib/utils.sh
2017-09-04 10:11:06 -04:00
Jonathan Knapp
808a8d48b7
Fix many shellcheck issues; ignore a few others
2017-09-04 10:09:47 -04:00
Victor Borja
e74c472829
Test current command with no installed version
2017-09-03 22:20:35 -05:00
vic
28d7921777
Merge pull request #221 from asdf-vm/plugin-list-all
...
Add plugin-list-all command
2017-09-03 20:00:02 -05:00
AJ Foster
e3e247752c
Allow spaces in .tool_versions file path
...
This helps to address (though may not completely fix) issue #202 .
2017-09-02 23:05:40 -04:00
Daniel Perez
b9fae70c0d
Add plugin-list-all command
2017-08-25 11:29:23 +09:00
Victor Hugo Borja
242d132afb
Find correct installation path for ref: versions
...
Noticed we had some duplicated logic for finding the
plugins installation path. This caused the bug described
by #213 where the installation command and the find_executable_path
were using different paths.
Fixes #213
2017-07-29 12:47:21 -05:00
Daniel Perez
78fbbaf584
Merge pull request #183 from doughsay/master
...
Use a git repository for installing plugins.
2017-07-26 18:49:15 +02:00
Chris Dosé
a0e5573960
Update plugins repo url.
2017-07-26 09:20:05 -07:00
Chris Dosé
5255f0e664
a little too zealous on the shellcheck warnings.
2017-04-19 20:40:06 -07:00
Chris Dosé
f399254219
code review feedback: fix all shellcheck warnings.
2017-04-19 20:37:03 -07:00
Chris Dosé
96c24e9255
code review feedback: git reset instead of git pull
2017-04-19 20:26:33 -07:00
William Ashton
baad7dd6d4
Query git for the current tag
...
Fixes #189
2017-04-15 22:50:43 -04:00
Henrik Nyh
d7ceb38b06
Avoid bash error when no version is set
...
Running "asdf current ruby" before installing any Rubies gave me:
/Users/henrik/.asdf/lib/utils.sh: line 73: [: !=: unary operator expected
No version set for ruby
2017-04-08 09:38:18 +01:00
Trevor Brown
974597ddc7
Correct sed command that removes asdf from PATH.
2017-03-27 11:04:52 -04:00
Chris Dosé
20cdbfe701
Use a git repository for installing plugins.
2017-03-26 16:44:22 -07:00
Trevor Brown
0f7757a910
Correct if statements in asdf-exec and utils.sh.
2017-03-25 14:50:30 -04:00
Daniel Perez
23f92987c0
Start adding tests for system version
2017-03-17 22:00:38 -04:00
Daniel Perez
f5152f255a
WIP: support system version
2017-03-17 22:00:37 -04:00
Trevor Brown
e6c69d4676
Make sure grep uses the correct settings when invoked by asdf.
2017-03-07 13:18:20 -05:00
Victor Hugo Borja
873dc5eb3e
Merge pull request #110 from vic/get_version_from_env
...
Get version from env if ASDF_${TOOL}_VERSION is defined.
2017-01-19 11:27:25 -06:00
Victor Hugo Borja
8709d197f1
Merge pull request #137 from vic/set-path-version
...
Allow `asdf local` and `asdf global` to take path: versions
2017-01-19 11:27:06 -06:00
Trevor Brown
5f3ff8ec26
Update the version in the README and utils.sh.
2016-12-21 18:45:57 -05:00
Victor Borja
716d8a93cd
Allow asdf local
and asdf global
to take path: versions
...
When given a path: version, just check that the directory
actually exists.
2016-12-19 00:25:29 -06:00
Trevor Brown
127f926391
Merge pull request #123 from vic/shims-remove
...
Shims remove on latest version uninstall (depends on #122 ).
2016-12-16 15:47:24 -07:00
Victor Borja
f4bc8b58ff
Merge remote-tracking branch 'origin/master' into get_version_from_env
2016-12-15 06:28:01 -06:00
Victor Borja
a1bc06fb82
Bugfix: ref:
and path:
versions are not read correctly.
...
Before this patch, with a `.tool-versions` file like:
```
lfe ref:master
```
`get_preset_version_for` would return `ref` instead of `ref:master`.
Same was happening for `path:` versions. Actually there was PR #95
on which I based my changes but instead of using space as delimiter
I went for using `|` which would be a lot more weird if present as
part of a file path, this also allows to specify paths which have
spaces which are much more frequent.
Closes #94 #95
2016-12-15 06:12:09 -06:00