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

Document watch mode #607

Merged
merged 3 commits into from
Mar 8, 2016
Merged

Document watch mode #607

merged 3 commits into from
Mar 8, 2016

Conversation

novemberborn
Copy link
Member

Document watch mode. Fixes #532.

Contains a squashed #597, so just check the last commit. Will rebase once #597 has landed.

@mention-bot
Copy link

By analyzing the blame information on this pull request, we identified @ben-eb, @sotojuan and @kasperlewau to be potential reviewers

@novemberborn
Copy link
Member Author

Pushed a fixup which:

  • changes sports to comes with
  • links to ignore-by-default's index.js for the ignored directories
  • uses <kbd> to mark up the rs input, reworded the sentence as well
  • updated example source patterns

Still to do:

  • add -S as shorthand for --source
  • support r + Enter to rerun all tests, in addition to rs + Enter
  • resolve whether source negation patterns should disable all default ignored directories, whether those default directories can be overriden, etc (this may need to be a follow-up issue)

@sindresorhus
Copy link
Member

support r + Enter to rerun all tests, in addition to rs + Enter

I meant just r. No Enter. What really is the point of having to press Enter?

resolve whether source negation patterns should disable all default ignored directories, whether those default directories can be overriden, etc (this may need to be a follow-up issue)

Yeah, let's not dilute this PR with that. Can you open a new issue?

@novemberborn
Copy link
Member Author

I meant just r. No Enter. What really is the point of having to press Enter?

This may be a bit tricky. It requires enabling raw mode on stdin which then seems to intercept ^C etc. It also seemed to affect my shell after killing AVA. Happy to open a ticket though as a future improvement?

I've added r + Enter now. I'm inclined to keep rs + Enter for those users with nodemon muscle memory (or who may use AVA and nodemon in the same project). Can remove if others disagree.

Yeah, let's not dilute this PR with that. Can you open a new issue?

#614


This has now been rebased against master. -S shorthand has been added.

@sindresorhus
Copy link
Member

Happy to open a ticket though as a future improvement?

👍

I'm inclined to keep rs + Enter for those users with nodemon muscle memory (or who may use AVA and nodemon in the same project).

Sure, that's fine, but r+enter should be the documented one.

@novemberborn
Copy link
Member Author

Sure, that's fine, but r+enter should be the documented one.

Right now they're both documented, with r + Enter being first.

@sindresorhus
Copy link
Member

Right now they're both documented, with r + Enter being first.

I don't see the point of documenting both. Your argument is that you have rs + Enter as muscle memory. I don't see why we would document rs to new users without that muscle memory and create overhead for them by making them have to choose which one to pick.

@novemberborn
Copy link
Member Author

Ticket: #615

@novemberborn
Copy link
Member Author

I don't see the point of documenting both. Your argument is that you have rs + Enter as muscle memory. I don't see why we would document rs to new users without that muscle memory and create overhead for them by making them have to choose which one to pick.

How would users realize rs also works? Other than accidentally. Maybe that's good enough though?

@sindresorhus
Copy link
Member

How would users realize rs also works? Other than accidentally. Maybe that's good enough though?

Isn't that the point? If they have to read the docs, they can just as easily use the shorter r+Enter version.

@novemberborn
Copy link
Member Author

You'd have to read the docs to even find out about r+enter though.

@sindresorhus
Copy link
Member

You'd have to read the docs to even find out about r+enter though.

Exactly. Unless it's muscle memory, users have to read the docs anyways, so there's really no reason to document both behaviors, when r is shorter. I consider rs a graceful handling of a mistyping, not something we'd want to officially support. IMHO, we should only have one way to do something.

@novemberborn
Copy link
Member Author

OK will edit in the morning. Good to go otherwise?

@sindresorhus
Copy link
Member

👍

'r' is 100% quicker to type than 'rs' 💥

Retain 'rs' for those with nodemon muscle memory.
@novemberborn
Copy link
Member Author

Updated. Anything else?

sindresorhus added a commit that referenced this pull request Mar 8, 2016
@sindresorhus sindresorhus merged commit cac933e into master Mar 8, 2016
@sindresorhus sindresorhus deleted the document-watch branch March 8, 2016 11:12
@sindresorhus
Copy link
Member

Looks good :)

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.

3 participants