Commit Graph

191 Commits

Author SHA1 Message Date
zkochan
a1ee21b907 feat: use a local registry similar to sinopia's storage 2017-02-27 00:10:01 +02:00
zkochan
455b40fe87 feat(bin): symlink executables when directories.bin specified
Close #156
2017-02-21 23:38:28 +02:00
zkochan
c1a8c71325 test: fix executable checking 2017-02-20 21:39:53 +02:00
zkochan
b6fddf4234 feat: remove link-local
It is broken since the bit `Pure Store` and seems nobody even noticed.
This functionality should be implemented in a separate tool that
uses pnpm's API.

BREAKING CHANGE:

Remove the link-local option
2017-02-18 22:45:55 +02:00
zkochan
de00178ca3 refactor: link API
BREAKING CHANGE:

Link API functions changed
2017-02-18 20:32:34 +02:00
zkochan
c7be0df6cd fix(link): don't reinstall linked packages
Close #597
2017-02-17 20:33:43 +02:00
zkochan
c3f4c0537f refactor: tests
Use readPkg and path.resolve instead of path.join+process.cwd()
2017-02-16 22:18:53 +02:00
zkochan
3b6ceaaebd refactor: use mkdirp-promise
Ref #441
2017-02-15 23:30:04 +02:00
zkochan
0eedfd53c3 feat: try to resolve URL dependencies to npm packages 2017-02-14 00:59:42 +02:00
zkochan
f763d6a321 fix(resolve): tarball depedencies have readable IDs 2017-02-13 23:32:38 +02:00
zkochan
ded4bd237c test(shrinkwrap): installation should fail when incorrect shasum
The installation should fail when the real shasum doesn't match the one in the shrinkwrap.yaml
2017-02-12 21:00:38 +02:00
zkochan
40bd4b630a feat(shrinkwrap): remove uninstalled deps from shrinkwrap.yaml 2017-02-12 18:24:55 +02:00
zkochan
686b88e223 feat(shrinkwrap): prune shrinkwrap file before saving 2017-02-12 15:59:37 +02:00
zkochan
da6ab05f5e test(shrinkwrap): add a tests to check shrinkwrap format
Ref #587
2017-02-12 13:45:58 +02:00
zkochan
5169b3725b feat: better shrinkwrap.yaml
Close #587

BREAKING CHANGE:

the `shrinkwrap.yaml` format has been changed
2017-02-12 13:25:04 +02:00
zkochan
04bc56c688 refactor(tests): move supporting functions to utils folder 2017-02-06 21:01:45 +02:00
zkochan
5e032a8512 feat: relink package from store, if it is not linked from there 2017-02-05 21:29:56 +02:00
zkochan
d3dcc5d3af feat: relink package to project if it has been refetched 2017-02-05 20:37:48 +02:00
zkochan
3f30c5c062 feat: rewrite packages in store only when they were mutated 2017-02-05 20:07:55 +02:00
zkochan
848922d551 feat(CLI): add pnpm verify command
Rel #585
2017-02-05 17:20:09 +02:00
zkochan
f119581587 feat: add verify() to the API that returns an array of modified package
Rel #585
2017-02-05 17:07:58 +02:00
zkochan
5f07768d2d feat: semver aware caching
Invalidate caching in semver aware way.

Remove caching into filesystem.

Rel #568, Close #580
2017-02-02 22:11:03 +02:00
zkochan
f7d96ac6e2 feat: reduce nesting in node_modules 2017-02-02 21:10:39 +02:00
zkochan
5a1b10c2dc test: breaking changes 2017-01-30 21:50:43 +02:00
zkochan
3d5ef20c6f fix(logging): better message on store mismatch
Close #495
2017-01-30 21:50:43 +02:00
zkochan
ebd93b430f test: move out the storage cache to a separate package 2017-01-30 21:40:38 +02:00
zkochan
97df5548fa test(bin): update pre-and-postinstall-scripts-example 2017-01-27 21:54:49 +02:00
zkochan
4e9fdc1477 fix(lifecycle): don't set NODE_PRESERVE_SYMLINKS to 1
With the new store and node_modules structure the pnpm leverages
symlinks preserving is not only unnecessary, it hurts.
2017-01-25 22:58:01 +02:00
zkochan
32e4130bea refactor: remove preserve-symlinks and flat-tree options
Close #546

BREAKING CHANGE:

Removed preserve-symlinks option

BREAKING CHANGE:

Removed flat-tree option
2017-01-25 22:12:38 +02:00
zkochan
9828efcbc0 fix(peer): link peers to non-bundled node_modules 2017-01-25 22:12:38 +02:00
zkochan
e3e94f14c7 test: skip shrinkwrap compatibility test on Node.js 4 2017-01-25 22:12:38 +02:00
zkochan
2c12199b3a fix: never preserve symlinks 2017-01-25 22:12:38 +02:00
zkochan
92cf129b19 chore: change repo URL 2017-01-23 22:36:01 +02:00
Zoltan Kochan
b9104a457c feat(global): change default global path
Use ~/.pnpm-cache as the default cache path.
Use the Node path for hosting the global pnpm package.
2017-01-21 18:38:47 +02:00
Andrey Popp
ca48f5d943 feat: make pnpm wait on lock
Also use `proper-lockfile` package. A similar thing which is yarn does.
2017-01-20 22:26:35 +02:00
zkochan
49932fcd73 revert: "test: temporarily skip GitHub tests"
This reverts commit 84878f8750.
2017-01-18 00:03:04 +02:00
Andrey Popp
aadcf0e656 test: rm unused artifacts in the fixture packages
Note that has-broken-symlink/has-broken.symlink.tar.gz contains a broken
link so the corresponding test case is useful.
2017-01-17 01:37:07 +02:00
Andrey Popp
d2375370a1 test: add test for a tarball with a broken symlink 2017-01-17 01:37:07 +02:00
zkochan
08adc17413 test: remove not needed test 2017-01-16 23:43:17 +02:00
zkochan
a7d508782c refactor: move reporters to separate packages 2017-01-16 20:49:18 +02:00
zkochan
383e772921 test: use verdaccio instead of sinopia
Unfortunately sinopia is not maintained anymore.
2017-01-15 18:43:18 +02:00
zkochan
84878f8750 test: temporarily skip GitHub tests
Ref #536
2017-01-13 23:24:22 +02:00
zkochan
59cd8cbede fix: packages can require themself
node_modules structure changed
2017-01-11 08:51:01 +02:00
zkochan
f678dd55d2 test: add new testing package
Add uses-pkg-with-self-usage testing package and rebuild sinopia cache
2017-01-11 08:31:22 +02:00
zkochan
1c00eb025e refactor: use is-windows package
For detecting Windows OS, use the is-windows package.
2017-01-09 18:08:15 +02:00
zkochan
c912ababf3 fix(bin): set NODE_PATH
When links are not preserved, set NODE_PATH for binstubs

Ref #527
2017-01-09 17:46:20 +02:00
zkochan
5810c446ba test: fix CLI tests 2017-01-08 20:48:28 +02:00
zkochan
832252192d test: move the testing folder out of the project
When the testing folder is inside the project folder, the lookup
includes the node_modules folder inside the project.
2017-01-08 19:46:10 +02:00
Zoltan Kochan
38837b131c Pure store (#524)
* feat: drop Node.js <= 6.3 support

BREAKING CHANGE:

drop support of Node.js pre-6.3

* refactor: remove the redundant subfolder in store

* refactor: rename linkPeers

* refactor: remove not used code

* feat: link each file separately

* refactor: change store structure

* refactor: resolve github dependencies to commits

* chore(package.json): pass --preserve-symlinks to ts-node

* test: temporarily skip failing tests

* refactor(git): use more human-friendly Git IDs

* refactor: resolve

* refactor: divide resolution and fetching

* refactor(fetch): better variable naming

* feat: add shrinkwrap.yaml

* test(shrinkwrap): shrinkwrap locks dependencies

* style: fix typing issue

* fix(fetch): properly link node_modules on repeat install

* refactor: comment skipped test with single-line comments

* fix: circular symlinks are avoided

* refactor(fetch): remove redundant type properties

* test: additional check for circular symlinks

* feat: saving dependency graph in node_modules instead of in store

BREAKING CHANGE:

Dependency graph moved out from store

* feat: add store.yaml with info about dependent projects

* refactor: remove name from FetchedPackage

* refactor: change the location of packages from npm in store

BREAKING CHANGE:

Structure of store changed

* refactor: change global store path

BREAKING CHANGE:

Move the store path out of ~/.pnpm

* refactor: remove justFetched from FetchedPackage

* refactor(install): use functional programming to filter deps

* refactor(install): remove redundant node_modules creation

* fix(install): installation of concurent circular dependencies

* feat: copy not link some packages

Packages that have install lifecycle events are copied not linked.

* fix(store.yaml): don't duplicate records

* perf: resolve a package only once per project

* test: concurrent installation of the same dependency

* fix: packages are not removed in the middle of fetch

* fix: dependencies are linked only once

* fix: make linking work on Windows

* fix: installing local dependencies on Windows

* fix: don't reinstall dependencies of the same package

* fix(bin): the run function always returns a Promise

* fix: use hard links to link files to the .resolutions folder

* fix: peers are linked into the correct location

* fix: bundled dependencies are not reinstalled

* refactor: remove unsymlink

It is not used anymore

* chore(CI): test on Node.js v4 as well

* refactor: use UPPER_CASE for constants

* chore(package): return support of Node.js v4

* fix: make pnpm Node.js 4 compatible again

* test: don't run tsnode with --preserve-symlinks

--preserve-symlinks makes tests fail on Node.js 4

* fix(bin): don't use --preserve-symlinks on Node pre-6.3

* test: use global stores in tests

* fix: flat-tree installation should not work on Node 4

* fix: show warning

When trying to install into a node_modules created by older pnpm

* refactor: change the global store location

From `~/.store` to `~/.pnpm-store`

* docs: note that some of the info is out of date

* test: fix typing error

* test: fix frequently failing test
2017-01-08 15:47:50 +02:00
zkochan
6a40852708 test: add missing awaits to CLI tests 2016-12-30 19:31:31 +02:00