Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tools/doc: add files to gitignore #17224

Merged
merged 1 commit into from
Nov 24, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -579,7 +579,7 @@ available-node = \
exit 1; \
fi;

run-npm-install = $(PWD)/$(NPM) install
run-npm-install = $(PWD)/$(NPM) install --production

tools/doc/node_modules/js-yaml/package.json:
cd tools/doc && $(call available-node,$(run-npm-install))
Expand Down
1 change: 0 additions & 1 deletion tools/doc/node_modules/.bin/marked

This file was deleted.

3 changes: 2 additions & 1 deletion tools/doc/node_modules/marked/lib/marked.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

60 changes: 18 additions & 42 deletions tools/doc/node_modules/marked/package.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 13 additions & 0 deletions tools/doc/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions tools/doc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,11 @@
"node": ">=6"
},
"dependencies": {
"marked": "^0.3.5",
"marked": "^0.3.5"
},
"devDependencies": {
"js-yaml": "^3.5.2"
},
"devDependencies": {},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this change? js-yaml is a full dependency of the doctool

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At some point it you hooked js-yaml to redirect to the copy that is in ESLint.

'use strict';
// Hack to load the js-yaml module from eslint.
// No other reason than that it’s huge.
const path = require('path');
const realJSYaml = path.resolve(
__dirname, '..', '..', '..', // tools/
'eslint',
'node_modules',
'js-yaml'
);
module.exports = require(realJSYaml);

This was overwritten anytime npm i was run.
(I agree we should also stop running npm i as part of the regular flows, since tools/doc should work as is in git)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, not running npm i is the fix here. It’s too bad the plans for releasing the doctool as a standalone module didn’t get anywhere so far, but semantically this is backwards :(

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree. I'll roll this back as soon as I finish testing the install-les make target.

"optionalDependencies": {},
"bin": "./generate.js"
}