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

Add ignore dependencies option in config file #37

Merged
merged 9 commits into from Jun 23, 2021

Conversation

SparshithNR
Copy link
Collaborator

@SparshithNR SparshithNR commented Jun 9, 2021

This change will provide a way to enable config files to ignore dependencies. #36 has more information on this.

No CLI option to ignore dependencies for now.

@SparshithNR SparshithNR changed the title Add cli option to ignore certain dependencies Add ignore dependencies option in CLI and config file Jun 23, 2021
Copy link
Contributor

@asakusuma asakusuma left a comment

Choose a reason for hiding this comment

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

looks great, few comments

lib/cli.js Outdated Show resolved Hide resolved
tests/cli-test.js Outdated Show resolved Hide resolved
@SparshithNR SparshithNR changed the title Add ignore dependencies option in CLI and config file Add ignore dependencies option in config file Jun 23, 2021
tests/cli-test.js Show resolved Hide resolved
@@ -38,6 +41,11 @@ async function main(cli, { policyDetails, setupProjectFn }) {
`The dependency ${dep} was found multiple times in the config file. Please refer Rules section in configuration.md`,
);
}
if (ignoredDependencies.includes(dep)) {
throw new Error(
`The dependency ${dep} was found in ignoredDependencies and custom configuration. Please refer Rules section in configuration.md`,
Copy link
Contributor

Choose a reason for hiding this comment

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

this is fine for now, but once #36 lands, we should create a shortend url for it and actually show a url here for people to lookup

@SparshithNR SparshithNR merged commit 4b92066 into supportedjs:main Jun 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants