linemanjs / heroku-buildpack-lineman

MIT License
4 stars 20 forks source link

Cache node_modules #8

Closed bkeepers closed 10 years ago

bkeepers commented 10 years ago

This merges in the changes from https://github.com/ddollar/heroku-buildpack-nodejs, which caches the node_modules between deploys. I didn't time it, but it makes deploys SIGNIFICANTLY faster.

searls commented 10 years ago

This seems super. Was thinking of doing the same myself and I should have thought to check heroku

On Wed, Nov 13, 2013 at 8:44 PM, Brandon Keepers notifications@github.com wrote:

This merges in the changes from https://github.com/ddollar/heroku-buildpack-nodejs, which caches the node_modules between deploys. I didn't time it, but it makes deploys SIGNIFICANTLY faster. You can merge this Pull Request by running: git pull https://github.com/bkeepers/heroku-buildpack-lineman cache-modules Or you can view, comment on it, or merge it online at: https://github.com/testdouble/heroku-buildpack-lineman/pull/8 -- Commit Summary --

  • Preserve ENV vars CPATH and CPPPATH (composable buildpacks)
  • cat npm-debug.log on exit
  • Merge pull request #34 from ryanbrainard/cat-npm-debug-log
  • add CONTRIBUTING.md
  • remove extra newline
  • update 'no version specified' devcenter url
  • Merge pull request #30 from davidjrice/preserve-env-vars
  • improve documentation in README
  • add a readme section for hackers
  • DRY up the hacking docs
  • ignore .DS_Store
  • use npm 1.3.x by default
  • comments
  • cache node_modules
  • only cache if there is a node_modules dir
  • always pass a cache dir
  • test node_modules caching
  • Merge node_modules caching from ddollar -- File Changes -- M .gitignore (1) A CONTRIBUTING.md (74) M bin/compile (35) M bin/test (17) A test/node-modules-caching/package.json (13) -- Patch Links -- https://github.com/testdouble/heroku-buildpack-lineman/pull/8.patch https://github.com/testdouble/heroku-buildpack-lineman/pull/8.diff
searls commented 10 years ago

Tested this out with the @testdouble/double-takes blog

Cold push:

real    2m13.696s
user    0m0.032s
sys 0m0.044s

Warm push:

real    1m38.309s
user    0m0.025s
sys 0m0.024s

Installing bundler & sass is probably the slowest aspect of the whole ordeal

Interestingly, the warm push had its slug size cut in half (from 50MB to 25MB)

jasonkarns commented 10 years ago

How bad do we need Sass? (I really just want LESS)

On Wed, Nov 13, 2013 at 8:56 PM, Justin Searls notifications@github.comwrote:

Tested this out with the @teestdouble/double-takes blog

Cold push:

real 2m13.696s user 0m0.032s sys 0m0.044s

Warm push:

real 1m38.309s user 0m0.025s sys 0m0.024s

Installing bundler & sass is probably the slowest aspect of the whole ordeal

Interestingly, the warm push had its slug size cut in half (from 50MB to 25MB)

— Reply to this email directly or view it on GitHubhttps://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453378 .

searls commented 10 years ago

If your project doesn't have Sass enabled, the heroku buildpack is smart enough to not install it and it won't slow you down at all.

On Wed, Nov 13, 2013 at 9:02 PM, Jason Karns notifications@github.comwrote:

How bad do we need Sass? (I really just want LESS)

On Wed, Nov 13, 2013 at 8:56 PM, Justin Searls notifications@github.comwrote:

Tested this out with the @teestdouble/double-takes blog

Cold push:

real 2m13.696s user 0m0.032s sys 0m0.044s

Warm push:

real 1m38.309s user 0m0.025s sys 0m0.024s

Installing bundler & sass is probably the slowest aspect of the whole ordeal

Interestingly, the warm push had its slug size cut in half (from 50MB to 25MB)

— Reply to this email directly or view it on GitHub< https://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453378>

.

— Reply to this email directly or view it on GitHubhttps://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453655 .

jasonkarns commented 10 years ago

Yeah, I mean I want to switch double-takes from Sass to LESS :smile:

On Wed, Nov 13, 2013 at 9:04 PM, Justin Searls notifications@github.comwrote:

If your project doesn't have Sass enabled, the heroku buildpack is smart enough to not install it and it won't slow you down at all.

On Wed, Nov 13, 2013 at 9:02 PM, Jason Karns notifications@github.comwrote:

How bad do we need Sass? (I really just want LESS)

On Wed, Nov 13, 2013 at 8:56 PM, Justin Searls notifications@github.comwrote:

Tested this out with the @teestdouble/double-takes blog

Cold push:

real 2m13.696s user 0m0.032s sys 0m0.044s

Warm push:

real 1m38.309s user 0m0.025s sys 0m0.024s

Installing bundler & sass is probably the slowest aspect of the whole ordeal

Interestingly, the warm push had its slug size cut in half (from 50MB to 25MB)

— Reply to this email directly or view it on GitHub<

https://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453378>

.

— Reply to this email directly or view it on GitHub< https://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453655>

.

— Reply to this email directly or view it on GitHubhttps://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453730 .

bkeepers commented 10 years ago

Without sass I'm getting 1m02.84s

searls commented 10 years ago

If you can find an alternative with helpers as nice as bourbon's for retina-images, transforms, and animations, I'm down. So far I haven't seen anything in Less-or-Stylus-world that's as nice.

On Wed, Nov 13, 2013 at 9:09 PM, Jason Karns notifications@github.comwrote:

Yeah, I mean I want to switch double-takes from Sass to LESS :smile:

On Wed, Nov 13, 2013 at 9:04 PM, Justin Searls notifications@github.comwrote:

If your project doesn't have Sass enabled, the heroku buildpack is smart enough to not install it and it won't slow you down at all.

On Wed, Nov 13, 2013 at 9:02 PM, Jason Karns notifications@github.comwrote:

How bad do we need Sass? (I really just want LESS)

On Wed, Nov 13, 2013 at 8:56 PM, Justin Searls < notifications@github.com>wrote:

Tested this out with the @teestdouble/double-takes blog

Cold push:

real 2m13.696s user 0m0.032s sys 0m0.044s

Warm push:

real 1m38.309s user 0m0.025s sys 0m0.024s

Installing bundler & sass is probably the slowest aspect of the whole ordeal

Interestingly, the warm push had its slug size cut in half (from 50MB to 25MB)

— Reply to this email directly or view it on GitHub<

https://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453378>

.

— Reply to this email directly or view it on GitHub<

https://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453655>

.

— Reply to this email directly or view it on GitHub< https://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453730>

.

— Reply to this email directly or view it on GitHubhttps://github.com/testdouble/heroku-buildpack-lineman/pull/8#issuecomment-28453898 .

bkeepers commented 10 years ago

Yeah, I mean I want to switch double-takes from Sass to LESS

I highly recommend stylus with nib. It's what SASS and LESS wished they were. I'm using it on https://github.com/bkeepers/github-notifications/pull/21 and absolutely love it.