browserify / factor-bundle

factor browser-pack bundles into common shared bundles
Other
400 stars 27 forks source link

Ensure output directory exists before creating write stream #84

Closed nwoltman closed 8 years ago

nwoltman commented 8 years ago

Fixes #83

nwoltman commented 8 years ago

@substack @terinjokes

terinjokes commented 8 years ago

I can understand this functionality being part of the CLI tool, but it doesn't belong as part of the library.

See also https://github.com/substack/factor-bundle/issues/70#issuecomment-148349467

nwoltman commented 8 years ago

That sounds reasonable. Would you accept a PR if I added output directory creation to the CLI tool? Would you accept this PR if I moved the output directory creation to the CLI tool?

nwoltman commented 8 years ago

Actually, adding it to the CLI isn't helpful. I'm using factor-bundle with grunt-browserify (like so) which directly uses factor-bundle/index.js, so that's where this needs to live.

terinjokes commented 8 years ago

@woollybogger then I think your best course of action is to create the output directory before using grunt-browserify.

nwoltman commented 8 years ago

@terinjokes Yeah that's what I'm currently doing. It's just pretty annoying because it adds 7 extra lines to my Gruntfile :disappointed: (which is also sort of funny because it only takes adding 2 lines in this repo to fix this for everyone). Oh well.