Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

watch.ts is causing ENOENT #53

Closed
Paladinium opened this issue Mar 22, 2016 · 6 comments
Closed

watch.ts is causing ENOENT #53

Paladinium opened this issue Mar 22, 2016 · 6 comments

Comments

@Paladinium
Copy link

Running npm start and having all source files watched to make browsersync work, I occasionally encounter errors that terminate the entire gulp process. I assume it's my IDE (webstorm) that may for a short time create temporary files leading to:

Error: ENOENT: no such file or directory, stat 'somedir/app/some.component.html___jb_tmp___'
at Error (native)

It would be great to have the watch process only watch for a defined set of file types (maybe make it configurable in config/seed.config.ts or config/project.config.ts). I don't have a good solution, but my temporary workaround for this issue results in a change to watch.ts:

// TODO: would be great not to explicitly list ts/html/json/css/whatever here:
plugins.watch([join(APP_SRC, '**/*.ts'), join(APP_SRC, '**/*.html'), join(APP_SRC, '**/*.json')], (e:any) => 
      runSequence(taskname, () => notifyLiveReload(e))
);
@Paladinium
Copy link
Author

Just figured out that it should be possible to disable the temporary file creation of webstorm since another project had the same issue reported: arboleya/coffee-toaster#57

Nevermind, it might be useful to have some kind of restriction for the watch process. What do you think?

@PatrickJS
Copy link
Member

The issue seems out of scope for the project. For support questions please ask in gitter, twitter, or stack overflow. I'll be closing this for now to keep the issues down

@Paladinium
Copy link
Author

That's fine, @gdi2290 . I found the solution and would like to share it (taken from arboleya/coffee-toaster#57 (comment)):

It is possible to disable temporary file creation in WebStorm as follows:

  • In the [IDE Settings] section of the [Settings] dialog box, click [General].
  • Uncheck the [Use "safe write"] check box.

@Paladinium
Copy link
Author

And with Webstorm 2016.1:

  • File -> Settings -> Appearance & Behavior -> System Settings -> Uncheck "Use safe write"

@PatrickJS
Copy link
Member

Can you add this to the wiki? Thanks!

@Paladinium
Copy link
Author

I can't access the wiki.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants