Commit Graph
100 Commits
Author SHA1 Message Date
Peter Dave Hello 265ec90532 [Dockerfile] Add missing name & version LABEL 2018-07-11 15:14:00 +08:00
Peter Dave Hello e2195b4c35 [Dockerfile] Use LABEL instead of deprecated MAINTAINER command 2018-07-11 15:13:57 +08:00
Peter Dave HelloandJordan Harband 62ee7cf998 [Refactor] bash_completion: Improve coding style 2018-05-21 19:59:01 +08:00
Peter Dave HelloandJordan Harband 113d807e5a [New] Support --no-progress for nvm install
Closes #1079.
2017-03-10 01:07:16 +08:00
Peter Dave HelloandJordan Harband d5dacdf80f [Fix] nvm debug: Fix sed syntax error in nvm_command_info() 2018-04-17 18:09:47 +08:00
Peter Dave Hello d3a9272a0c [Refactor] Speedup nvm_list_aliases() 2018-04-18 17:03:47 +08:00
Peter Dave HelloandJordan Harband d9dc8464fd [Doc] Add macOS install script note about Git
Closes #1782
2018-04-13 01:14:39 +08:00
Peter Dave HelloandJordan Harband 685312d600 [Fix] Remove $NVM_DIR trailing slash automatically, fix #1708 2018-04-12 14:14:58 +08:00
Peter Dave HelloandJordan Harband 0731003cfe [New] Integrate eclint to test partial coding style 2018-02-26 02:29:38 +08:00
Peter Dave HelloandJordan Harband ca66a13710 nvm debug: Improve OS version detection 2018-02-24 02:53:40 +08:00
Peter Dave HelloandJordan Harband 8ff437ae51 [Doc] Fix manual install & upgrade guide, fix #1772 2018-04-12 23:58:30 +08:00
Peter Dave Hello b15709e637 Turn off wget's output in nvm_get_latest()
curl output is turned off by `-s` in the same place, we should unify the
behavior on wget, also, this help removes those wget outputs that can't
fit our coding style tests. cc #1739
2018-04-12 23:44:27 +08:00
Peter Dave HelloandJordan Harband 37e0977e60 install.sh: Improve install.sh prompt output, add a newline 2018-04-10 15:53:33 +08:00
Peter Dave HelloandJordan Harband 2850e65b62 [Docs] Fix some typos 2018-03-03 21:18:42 +08:00
Peter Dave HelloandJordan Harband d6fa67166c [Fix] reinstall-packages: Prevent install/link when no packages found
Fixes #1744.
2018-02-27 14:05:33 +08:00
Peter Dave Hello 25b7f264d5 [Fix] Use nvm_echo instead of echo directly 2018-02-28 02:16:24 +08:00
Peter Dave HelloandJordan Harband 750571056c [Fix] Correct most of the wrong indentation 2018-02-26 02:20:21 +08:00
Peter Dave HelloandJordan Harband 544c3f4caa [New] Add EditorConfig to help maintain part of coding style 2018-02-21 01:26:02 +08:00
Peter Dave HelloandJordan Harband e7b42198b4 [Fix] Improve .nvmrc reading process
Fixes #1015. Fixes #1712.
2018-02-20 03:34:43 +08:00
Peter Dave HelloandJordan Harband 5f53caadad [Refactor] Use grep -q parameter instead of redirect to /dev/null 2018-02-03 11:29:31 +08:00
Peter Dave HelloandJordan Harband 9c42470347 [New] Add "$PATH" to nvm debug output 2018-02-06 08:17:20 +08:00
Peter Dave Hello 9f34b3e95c Remove trailing space 2018-02-26 01:03:01 +08:00
Peter Dave Hello 41ec44f6b5 Add missing final newline in test script 2018-02-26 01:02:41 +08:00
Peter Dave Hello 2cd2c0f72e Remove useless trailing newlines 2018-02-26 01:01:30 +08:00
Peter Dave HelloandJordan Harband f3076d14c9 [Fix] Add missing "command" prefixes for few commands 2018-02-20 04:05:47 +08:00
Peter Dave Hello bb803492d8 Remove duplicate code in nvm_npm_global_modules()
No matter what's the result of the condition here, the path is the same.
2018-02-22 09:43:09 +08:00
Peter Dave HelloandJordan Harband f290ccf1d5 [Fix] Add missing "command" prefix for "tr", fix #1725 2018-02-19 13:59:26 +08:00
Peter Dave Hello 225e447b54 [Doc] Update Docker image build info in README.md 2018-02-19 00:27:04 +08:00
Peter Dave HelloandJordan Harband 77da9f5a6d Optimize ShellCheck installation in Docker image
Use pre-built static release binary instead of building ShellCheck from
the source code, this change would save disk space, time, and much
computing resources.
2018-01-18 00:33:41 +08:00
Peter Dave HelloandJordan Harband 3ed47431f8 [New] Print $SHLVL in nvm debug 2017-11-05 03:25:04 +08:00
Peter Dave HelloandJordan Harband aad269d224 Display FreeBSD and SunOS with correct caps 2018-02-12 02:15:01 +08:00
Peter Dave HelloandJordan Harband a23f7169a6 [Fix] Correct nvm.sh indent 2018-01-26 11:30:57 +08:00
Peter Dave Hello 2a8a81da94 [Fix] ShellCheck SC1117 in nvm.sh & install.sh 2017-12-14 03:26:17 +08:00
Peter Dave Hello fce7f4ed13 [Fix] Disable ShellCheck SC2207 in bash_completion line 14 2017-12-14 02:11:50 +08:00
Peter Dave Hello 9c25a8f316 [Cleanup] Remove ghc related things in .travis.yml, cc #1619 2017-10-22 00:42:07 +08:00
Peter Dave Hello a461a0fffc [Fix] install.sh shouldn't use not existed $NVM_PROFILE 2017-10-04 10:10:47 +08:00
Peter Dave Hello 73ad812215 Remove the manual ShellCheck install proecss on Travis CI 2017-09-29 00:22:43 +08:00
Peter Dave Hello d535c97d0f Enhance nvm debug with more tools info 2017-09-21 22:09:15 +08:00
Peter Dave HelloandJordan Harband 7753b24948 [Docs] Update README.md for Alpine linux reference
Add 4 packages as Alpine Linux wiki suggested:
(grep util-linux binutils findutils)

https://wiki.alpinelinux.org/wiki/How_to_get_regular_stuff_working
2017-09-07 18:00:08 +08:00
Peter Dave HelloandJordan Harband 248706d5f8 [New] Clean up git reflog history before git gc 2017-07-14 00:37:58 +08:00
Peter Dave Hello ab591b07ef [New] Print $TERM_PROGRAM in nvm debug if it exists 2017-07-14 01:48:27 +08:00
Peter Dave HelloandJordan Harband 38a568c9c9 [New] Add --auto to git gc to speed up install & upgrade 2017-07-11 09:19:02 +08:00
Peter Dave HelloandJordan Harband f37ddea78f [Docs] Fix typos in Docker instructions 2017-07-08 18:50:06 +08:00
Peter Dave HelloandJordan Harband 1e69c4c77d [New] Speedup process to install nvm from git by dropping commit history 2017-04-02 15:49:01 +08:00
Peter Dave HelloandJordan Harband 3ac49e5ef1 [New] Introduce Docker environment for nvm 2017-04-02 08:03:32 +08:00
Peter Dave Hello 0356839d05 [Fix] Adjust $CURL_COMPRESSED_FLAG usage for curl, fix #1562 2017-06-27 15:04:28 +08:00
Peter Dave HelloandJordan Harband b5034bb2b2 [bash completion] add missing install-latest-npm; remove undocumented clear-cache 2017-06-23 14:21:10 +08:00
Peter Dave Hello 11370fe823 [Fix] curl should fail if something wrong, fix #1556 2017-06-14 10:58:38 +08:00
Peter Dave Hello c3c2d350e9 [Tests] Fix cache for WITHOUT_CURL tests in Travis 2017-05-19 13:58:14 +08:00
Peter Dave Hello f38d21c529 [Docs] Improve "Problems" README section readability 2017-04-13 17:56:46 +08:00
Peter Dave HelloandJordan Harband 7aa3448259 [Tests] Add curl back when WITHOUT_CURL test done since cache needs it 2017-04-09 13:13:25 +08:00
Peter Dave HelloandJordan Harband a66a9caa1c [Tests] Use node v0.10.7 for thread para test as other install from src tests 2017-04-09 13:08:04 +08:00
Peter Dave Hello 229c7e6f0c [Tests] Test "make release" in Travis CI 2017-04-09 15:16:13 +08:00
Peter Dave Hello d80686c7cd [Makefile] Introduce _ensure-current-version to ensure version tags 2017-04-09 15:09:31 +08:00
Peter Dave Hello 153f8e7b31 [Fix] To confirm curl exists before detecting curl libz feature 2017-04-09 13:44:07 +08:00
Peter Dave HelloandJordan Harband e87f395b7a [Refactor] minor "if" and "return" improvement 2017-04-06 03:55:42 +08:00
Peter Dave Hello 2ec2d31012 [Tests] Re-enable WITHOUT_CURL tests 2017-04-06 14:52:26 +08:00
Peter Dave HelloandJordan Harband daa9c3604d [Fix] To confirm curl exists before detecting curl libz feature 2017-04-06 05:20:55 +08:00
Peter Dave HelloandJordan Harband ec3ba1973a [New] install.sh: Parallel script download jobs 2017-04-05 04:54:38 +08:00
Peter Dave HelloandJordan Harband c6866eeb37 [Test] "nvm alias" lts test bug fix 2017-04-02 14:34:04 +08:00
Peter Dave HelloandJordan Harband e84bcaabdc [Refactor] Improve profile detection in install script 2017-04-03 23:06:04 +08:00
Peter Dave HelloandJordan Harband 3f5fd57881 [Refactor] Reduce a sed command with pipe 2017-04-05 04:58:34 +08:00
Peter Dave HelloandJordan Harband f524bcb973 [Fix] Correct indent in install.sh 2017-04-05 05:01:54 +08:00
Peter Dave Hello a0534b720a [Tests] Reduce apt package dependencies calculation complexity 2017-04-02 16:48:28 +08:00
Peter Dave Hello 424056c839 [Tests] Remove ShellCheck manual dependency install under Ubuntu 14.04 2017-04-02 15:49:01 +08:00
Peter Dave Hello 18df8e3d2e [Tests] Remove ppa source since we migrated to Ubuntu Trusty 2017-04-02 07:24:56 +08:00
Peter Dave HelloandJordan Harband 5776cc952a [copyright] update to 2017 2017-03-29 17:54:15 +08:00
Peter Dave Hello 6c24346af5 [New] Add missing commands in bash_completion 2017-03-30 19:49:30 +08:00
Peter Dave HelloandJordan Harband 450088e51a [Refactor] Improve if conditoion logic in "use" 2017-03-30 00:41:31 +08:00
Peter Dave HelloandJordan Harband 9a6e657e53 [Docs] Remove curl --compressed notes since we added its detection 2017-03-29 17:51:23 +08:00
Peter Dave HelloandJordan Harband 8fc7e854de [Tests] Comment out ksh dependency installation, cc #574
- Mistakenly uncommented in 70370a857f
 - per afba4e08fd / #574
2017-03-29 18:05:15 +08:00
Peter Dave HelloandJordan Harband 93c1036758 [Tests] Move to Ubuntu 14.04 on Travis CI
Since Ubuntu 12.04 is pretty old now, it's also going to EOL next month,
maybe we can just move on Ubuntu 14.04 first.
2017-03-26 05:19:57 +08:00
Peter Dave HelloandJordan Harband a36af70571 [Docs] Update issue #900 title in README.markdown 2017-03-28 22:47:34 +08:00
Peter Dave HelloandJordan Harband 059ab0e1ac [Refactor] Make the code a little bit cleaner 2017-03-28 15:27:49 +08:00
Peter Dave HelloandJordan Harband 676fff0219 [completions] Remove nospace in bash_completion 2017-03-26 06:10:53 +08:00
Peter Dave HelloandJordan Harband 7b253c8c0a [New] Supercharge nvm debug output
Try to get shell version, OS and its version, curl/wget/git version.
2017-03-23 14:48:00 +08:00
Peter Dave Hello f344d0694b [Tests] Move cabel, nvm & npm install into TravisCI "install" section 2017-03-26 05:22:48 +08:00
Peter Dave Hello d9704471ff [Tests] Cache "node_modules" in CI 2017-03-26 04:06:32 +08:00
Peter Dave Hello 82aaa0a20d [Tests] Do not install nodejs, npm deps for SHELLCHECK 2017-03-25 16:57:42 +08:00
Peter Dave Hello e41197ea94 [Tests] Improve npm dependencies installaion in travis ci 2017-03-24 13:46:50 +08:00
Peter Dave HelloandJordan Harband 6ef2be8db4 [Docs] Get https://nodejs.org/dist header instead of its body, fix #1451 2017-03-23 14:12:31 +08:00
Peter Dave HelloandJordan Harband d465493832 [Docs] Use https protocol for nodejs.org in issue template 2017-03-23 14:07:07 +08:00
Peter Dave HelloandJordan Harband 0e5fba2dfb [Docs] Also add --compressed for curl in issue template, cc #1437 2017-03-23 14:01:46 +08:00
Peter Dave Hello 973dfc6d4a [New] Dynamically detect if curl supports --compressed 2017-03-23 16:51:20 +08:00
Peter Dave Hello 6a3b1dd2c3 [New] Enable curl auto compression/decompression
Enable `--compressed` parameter on curl to automatically enable
compression on request content by sending coressponding header, if the
server side supports compression format like deflate or gzip, curl will
also decompress the content automatically, so there is no additional
works need to done manually on client side, but just enjoy the benifits
of bandwidth and time saving!

Take https://nodejs.org/dist/index.tab as an example which is last
modified on Tue, 14 Mar 2017 22:41:05 GMT, the compressed transmission
only take 4829 bytes howevet the not compressed on taks 48000 bytes,
which is about 10 times larger!

This feature can be traced back to Sep 3 2002, in curl commit:
 - https://github.com/curl/curl/commit/64bbe9dfafc6693a96b742f3133c636385835a19

So should be supported on various versions widely.
2017-03-23 16:51:20 +08:00
Peter Dave HelloandJordan Harband 4c97828f79 Update .gitattributes 2017-03-23 04:52:46 +08:00
Peter Dave Hello ccd9697ef2 Delete .npmignore 2017-03-23 08:47:53 +08:00
Peter Dave HelloandJordan Harband 20a40dd8c2 [Docs] Update CONTRIBUTING.md 2017-03-23 04:46:49 +08:00
Peter Dave Hello 237c3a78e2 [Tests] Add retry on urchin setup which has no built in retry feature
Unlike other built in functions like git fetch or apt-get dependencies,
manual installations won't have retry by default, enabling retry could
help reduce the impact of network issues and furthur prevent getting
build error like Job #1956.21:
- https://travis-ci.org/creationix/nvm/jobs/212640007

Ref:
- https://docs.travis-ci.com/user/common-build-problems/
2017-03-22 20:42:33 +08:00
Peter Dave HelloandJordan Harband fa3631fee3 [Refactor] Add nvm_has_non_aliased 2017-03-20 16:57:26 +08:00
Peter Dave HelloandJordan Harband 316c9f34c6 [Performance] Use awk's comparison to save a pipe to grep 2017-03-20 04:50:32 +08:00
Peter Dave HelloandJordan Harband 6cb12b0f99 [Performance] Improve awk usage 2017-03-21 04:23:53 +08:00
Peter Dave HelloandJordan Harband 6ed73b0696 [Refactor] Improve sed usage for performance 2017-03-20 17:53:44 -07:00
Peter Dave HelloandJordan Harband 039afb9470 [Docs] Update Installation section
1. If we are not going to install nodejs or io.js from source, we may
not need to have c++ compiler or libssl-dev package
2. the `build-essential` and `libssl-dev` packages should work on all
the Debian and Ubuntu based GNU/Linux distros
3. Remove useless blank lines
2017-03-16 04:22:29 +08:00
Peter Dave Hello b879628394 [Fix] declare MANPATH if and only if it's not set
By manpath's man page in Ubuntu 16.04:

> If $MANPATH is set, manpath will simply display its contents and issue
> a warning.

By fa22d712ff for #1413, `nvm` now will
declare the "MANPATH" variable, no matter if it's set or not, so in the
situation that $MANPATH is set, you'll get the warning:

> manpath: warning: $MANPATH set, ignoring /etc/manpath.config
2017-03-19 02:19:14 +08:00
Peter Dave HelloandJordan Harband 50ae1e5199 [Fix] Install failed should return correct exit status, fix #1347 2016-12-10 00:20:04 +08:00
Peter Dave Hello 952d0067b3 [Fix] bash_completion should make sure nvm loaded 2017-03-15 14:34:28 +08:00
Peter Dave Hello 911ff87601 [Fix] bash_completion source prompt, remove && 2017-03-15 14:34:28 +08:00
Peter Dave Hello 9593616b8c [Fix] NVM_PROFILE bash/zsh detection in installation 2017-03-15 14:34:28 +08:00
Peter Dave Hello d8538dad84 [Refactor] nvm.sh minor refactor 2017-03-14 17:45:54 +08:00