CleverStack / angular-seed

The AngularJS based Modular Frontend for CleverStack, MEAN and so much more
http://youtube.com/watch?v=-4ArURHExhQ
MIT License
118 stars 36 forks source link

karma auto-watch hogs resources #29

Closed adnan-i closed 10 years ago

adnan-i commented 10 years ago

While running karma start --auto-watch, the "node" process that was created by it was constantly using around 50% of processor time (on 2.2 i7 processor).

This Karma issue (https://github.com/karma-runner/karma/issues/389) explains that is because of the greedy file pattern on components folder.

After I changed the pattern from:

{ pattern: 'app/components/**/*.js', included: false, served: true },

to

{ pattern: 'app/components/**/*.js', included: false, served: true, watched: false },

the "node" process fell down to reasonable 2%.

With this change the developer will have to re-start the runner when components folder is changed, but that folder is not updated too often anyway.

I guess I could have sent a PR for this, but the change is too small for PR.

leostera commented 10 years ago

Thanks. A PR would have been alright, regardless of the size. I'll fix this immediately.