yeoman watch without server #529

Closed
jakubroztocil opened this Issue Sep 22, 2012 · 10 comments

7 participants

@jakubroztocil
$ yeoman watch

Yeoman`s watch task is integrated within `yeoman server` to combine
  the dev server, re-compilation and live reloading of changed assets.

  Feel free to run yeoman server instead!

Am I missing something or is it really not possible to have re-compilation without the server? I need my app to be served by my backend server and don't care about live reloading.

@mklabs
Contributor
mklabs commented Sep 22, 2012

Feel free to bypass this https://github.com/yeoman/yeoman/blob/master/cli/bin/yeoman#L73-78

I don't remember why it was added, but that's what you want to kill off if you want to be able to run yeoman watch.

Alternately, you can use grunt watch directly.

@addyosmani
Member

As a part of simplifying the commands users are exposed to/the workflow, we decided we wanted to get more people using server rather than just watch. I think this should stay the way it is at the moment with the above used as reference for anyone wishing to re-enable.

@addyosmani addyosmani closed this Sep 22, 2012
@jakubroztocil

As a part of simplifying the commands users are exposed to/the workflow, we decided we wanted to get more people using server rather than just watch.

The decision to make the command private actually seems to go against the goal to simplify the workflow:

  • watch is used by many similar tools (compass watch, brunch watch, coffee watch, …) so it would be good to keep to UI predictable.
  • Even though watch is a subset of server's functionality, they are still two different things.
  • Having to use an external command (grunt watch) doesn't really make the workflow more simple.
  • If grunt watch is the way to "watch" with yeoman, then it would be good to suggest it in the "I refuse to watch" error message.
@sindresorhus
Member

I think I have to agree with @jkbr. We should reconsider.

@sindresorhus sindresorhus reopened this Sep 22, 2012
@edwardoriordan

Alternately, you can use grunt watch directly.

Won't you have to change the name of the grunt file from Gruntfile.js to to grunt.js to do this?

I can understand the need to cover the 90% use case but making it so that you have hack yeoman to use it seems a bit drastic.

What about a flag you can pass to watch? yeoman watch --yes-please!

@addyosmani
Member

cc @paulirish as he originally proposed we hide :)

@paulirish
Member

Well.. these are good points. :) Let's reconsider.

What we can do is throw a helpful message out that mentions server but continues anyway..

FYI: Yeoman`s watch task is integrated within `yeoman server` to combine
  the dev server, re-compilation and live reloading of changed assets.

Continuing anyway...

decent?

@sindresorhus
Member
@sleeper
Contributor
sleeper commented Sep 23, 2012

👍

@jakubroztocil

@paulirish sounds great 👍

@sindresorhus sindresorhus added a commit that closed this issue Sep 24, 2012
@sindresorhus sindresorhus Implement text from @paulirish when the watch task is run
And let the watch task run.

Fixes #529
c539e87
@szinya szinya pushed a commit to menthainternet/yeoman that referenced this issue Sep 17, 2014
@sindresorhus sindresorhus Implement text from @paulirish when the watch task is run
And let the watch task run.

Fixes #529
f297668
@sindresorhus sindresorhus added a commit that referenced this issue Apr 24, 2015
@sindresorhus sindresorhus Implement text from @paulirish when the watch task is run
And let the watch task run.

Fixes #529
2d6fec9
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment