Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

Improve CLI error message when no files are specified #3066

Merged
merged 2 commits into from
Jul 25, 2017

Conversation

dupski
Copy link
Contributor

@dupski dupski commented Jul 22, 2017

PR checklist

Overview of change:

The tslint CLI now gives an unhelpful Missing files error when you do not specify any files to lint or the --project argument.

tslint-err1

This PR improves the error message so future people won't have to google it like I did :)...

tslint-err2

I have updated and run the tests.

CHANGELOG.md entry:

[enhancement] Improved CLI error message when no filenames are specified

@palantirtech
Copy link
Member

Thanks for your interest in palantir/tslint, @dupski! Before we can accept your pull request, you need to sign our contributor license agreement - just visit https://cla.palantir.com/ and follow the instructions. Once you sign, I'll automatically update this pull request.

assert.include(stderr, "Missing files", "stderr should contain notification about missing files");
assert.include(stderr,
"No files specified. Use --project to lint a project folder.",
"stderr should contain notification about ");
Copy link
Contributor

Choose a reason for hiding this comment

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

this string looks truncated

Copy link
Contributor Author

Choose a reason for hiding this comment

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

So it does, I'll check it out.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I have corrected @ajafff, sorry about that!

@adidahiya adidahiya merged commit 8c8f604 into palantir:master Jul 25, 2017
@dupski dupski deleted the f-files-errormsg branch July 26, 2017 05:45
HyphnKnight pushed a commit to HyphnKnight/tslint that referenced this pull request Apr 9, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants