Skip to content
This repository was archived by the owner on Nov 8, 2024. It is now read-only.

Commit d80bef6

Browse files
committed
chore: do not use lock file
See #1184 (comment)
1 parent 9f6f7b0 commit d80bef6

File tree

6 files changed

+5
-1785
lines changed

6 files changed

+5
-1785
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
package-lock.json
2+
npm-shrinkwrap.json
3+
14
/coverage
25
/docs/_build
36
node_modules

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
save-exact
2+
package-lock=false

docs/internals.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ C++ dependencies
109109

110110
Dredd uses `Drafter <https://github.com/apiaryio/drafter>`__ for parsing `API Blueprint`_ documents. Drafter is written in C++ and needs to be compiled during installation. Because that can cause a lot of problems in some environments, there’s also pure JavaScript version of the parser, `drafter.js <https://github.com/apiaryio/drafter.js>`__. Drafter.js is fully equivalent, but it can have slower performance. Therefore there’s `drafter-npm <https://github.com/apiaryio/drafter-npm/>`__ package, which tries to compile the C++ version of the parser and in case of failure it falls back to the JavaScript equivalent. Dredd depends on the `drafter-npm <https://github.com/apiaryio/drafter-npm/>`__ package.
111111

112-
That still proved problematic for Dredd though. The current solution is to provide an `npm-shrinkwrap.json <https://docs.npmjs.com/files/shrinkwrap.json>`__ file with the `Dredd Transactions`_ library, which completely excludes `protagonist <https://github.com/apiaryio/protagonist>`__, i.e. the compiled C++ binding. Unlike ``package-lock.json``, the file can be distributed inside an npm package. The exclusion is performed by a ``postshrinkwrap`` npm script.
112+
That still proved problematic for Dredd though. The current solution is to provide an `npm-shrinkwrap.json <https://docs.npmjs.com/files/shrinkwrap.json>`__ file with the `Dredd Transactions`_ library, which completely excludes `protagonist <https://github.com/apiaryio/protagonist>`__, i.e. the compiled C++ binding. Unlike ``package-lock.json``, the file can be distributed inside an npm package. The exclusion is performed by a ``postshrinkwrap`` npm script. This didn't work well with Dredd's ``package-lock.json``, so currently Dredd's dependency tree is not locked for local or CI installations.
113113

114114

115115
Supported Node.js versions

0 commit comments

Comments
 (0)