Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Persistent cache #426

Merged
merged 3 commits into from
Feb 14, 2018
Merged

Persistent cache #426

merged 3 commits into from
Feb 14, 2018

Conversation

goto-bus-stop
Copy link
Member

Cache transform results in ~/.cache/bankai using
browserify-persist-fs.

On the ./example folder in this repo, results:

$ time npm run build # cold run
npm run build  13.79s user 0.35s system 159% cpu 8.843 total
$ time npm run build # warm run
npm run build  9.64s user 0.30s system 170% cpu 5.818 total

This is already a pretty big win, but on a larger app it should be
much much more noticeable still—the more files, the bigger the
win :).

Cache transform results in `~/.cache/bankai` using
[browserify-persist-fs](https://github.com/martinheidegger/browserify-persist-fs).

This should not be merged until browserify/module-deps#127
is, since currently this does not work great with watchify (if I
understand the linked PR correctly).

Anyway, on the `./example` folder in this repo, results:

```bash
$ time npm run build # cold run
npm run build  13.79s user 0.35s system 159% cpu 8.843 total
$ time npm run build # warm run
npm run build  9.64s user 0.30s system 170% cpu 5.818 total
```

This is already a pretty big win, but on a larger app it should be
much much more noticeable still.
Copy link
Member

@yoshuawuyts yoshuawuyts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@goto-bus-stop goto-bus-stop merged commit b4a0f9c into master Feb 14, 2018
@goto-bus-stop goto-bus-stop deleted the cache branch February 14, 2018 13:56
goto-bus-stop added a commit that referenced this pull request Feb 21, 2018
This reverts commit b4a0f9c.

The persistent cache doesn't work with transforms that emit 'file'
events right now, so we'll have to figure that out before enabling it.
goto-bus-stop added a commit that referenced this pull request Feb 23, 2018
This reverts commit b4a0f9c.

The persistent cache doesn't work with transforms that emit 'file'
events right now, so we'll have to figure that out before enabling it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants