micromatch / braces

Faster brace expansion for node.js. Besides being faster, braces is not subject to DoS attacks like minimatch, is more accurate, and has more complete support for Bash 4.3.
https://github.com/jonschlinkert
MIT License
207 stars 47 forks source link

refactor #24

Closed jonschlinkert closed 5 years ago

paulmillr commented 5 years ago

@jonschlinkert just a quick note. to-regex — which adds non-core functionality as far as I see — adds 0.3MB of deps. That's a lot, because without it there are 0 deps.

to-regex  │ 21          │ 0.30M

Any chance we could move braces.toRegex out to a new pkg? Or just add a quick README notice on usage — no need for a new pkg.

jonschlinkert commented 5 years ago

which adds non-core functionality as far as I see

Are you saying we should drop regex support from braces? How much of the 300k is safe-regex (the library that checks for catastrophic backtracking to prevent DDoS)?

If this gets too complicated I'll have to plan time in the future to work on this.

paulmillr commented 5 years ago

@jonschlinkert here's to-regex (it says 0.13MB but in the end it's 0.3MB)

┌─────────────────┬────────────┬───────┐
│ name            │ children   │ size  │
├─────────────────┼────────────┼───────┤
│ define-property │ 7          │ 0.11M │
├─────────────────┼────────────┼───────┤
│ extend-shallow  │ 4          │ 0.04M │
├─────────────────┼────────────┼───────┤
│ regex-not       │ 2          │ 0.02M │
├─────────────────┼────────────┼───────┤
│ safe-regex      │ 1          │ 0.02M │
├─────────────────┼────────────┼───────┤
│ 4 modules       │ 9 children │ 0.13M │
└─────────────────┴────────────┴───────┘
paulmillr commented 5 years ago

@jonschlinkert as far as I see from the readme there's no support for regex api in the stable version of braces. So, in this case, i'd argue for keeping the api just as simple; and adding a readme notice on how to convert to RegExps.

paulmillr commented 5 years ago

YAY! 🌈

Any ETA on the release?

jonschlinkert commented 5 years ago

Any ETA on the release?

it's done. I just need to wrap it up and release. probably today

paulmillr commented 5 years ago

Great to see one less tool (appveyor).

jonschlinkert commented 5 years ago

@paulmillr FWIW I use a tool to generate documentation, the badges are in a template, so they'll automatically be updated. The appveyor badge is excluded if there is no .appveyor.yml file.

paulmillr commented 5 years ago

@jonschlinkert ping!

jonschlinkert commented 5 years ago

What are you pinging about @paulmillr?

paulmillr commented 5 years ago

Let's release it 😃

jonschlinkert commented 5 years ago

Let's release it 😃

Are you volunteering to do the docs and changelog? :)

paulmillr commented 5 years ago

Working on anymatch & chokidar updates right now.

paulmillr commented 5 years ago

I’ve prepared new builds — Chokidar is 1/8th of previous size and feels super lean now. Can’t wait on getting these packages released!

jonschlinkert commented 5 years ago

Can’t wait on getting these packages released!

I'll be working on it this weekend.

jonschlinkert commented 5 years ago

@paulmillr how's everything working out?

paulmillr commented 5 years ago

@jonschlinkert it’s awesome, we’re fixing tests across platforms and waiting for node 8.16

jonschlinkert commented 5 years ago

we’re fixing tests across platforms and waiting for node 8.16

I hope I didn't break anything!