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

Already on GitHub? Sign in to your account

Late-stage .lateslugignore removal of files before slug compilation (soft recreation of rolled back heroku change 179) #56

Closed
wants to merge 9 commits into
from

Conversation

Projects
None yet
4 participants

pavgup commented Dec 29, 2012

Unfortunately, the .slugignore file is processed before the asset precompile stage of the buildpack. This was changed (https://devcenter.heroku.com/changelog-items/179) and then pretty quickly rolled back (https://devcenter.heroku.com/changelog-items/185).

The original goal still seems quite sound. So, recognizing the global adjustment is rough, I've gone after the next logical step back by adjusting the buildpack. My implementation relies on a an optional .lateslugignore file and if the buildpack finds the file it will act on the extensions found, or just keep moving quietly along (i.e., new functionality at little cost to legacy users)..

The benefit here is primarily in much smaller slug sizes and streamlined deployments. This works for me, but feel free to reject/accept this -- I don't want to take and change this work without giving back, at least a little.

I like this idea a lot, but is there a reason that the .lateslugignore only works with file extensions and doesn't also accept directories like .slugignore does (see https://devcenter.heroku.com/articles/slug-compiler#ignoring-files-with- )? I'd much prefer to be able to make my .lateslugignore something like:

/app/assets
/lib/assets
/vendor/assets

👍

Contributor

schneems commented Sep 25, 2013

I don't want to take and change this work without giving back, at least a little.

Thanks :)

Anectdotally i've seen a huge number of support tickets come in based on people who forgot they were using .slugignore in their project. It is a source of confusion to new developers on a project and to the developers who wrote that slugignore file. For removing assets I typically recommend using Rake enhance to manually rm those directories.

This PR has been open for 9 months and you can get this result via running code that enhances assets:precompile. Think we're going to close this for now.

Thanks again for the PR though sorry for the extreme delayed response :)

@schneems schneems closed this Sep 25, 2013

@sh19910711 sh19910711 pushed a commit to social-snippet/heroku-buildpack-ruby that referenced this pull request Oct 7, 2014

@zeke zeke Merge pull request #56 from heroku/pipefail
use pipefail to force exit when `npm install` fails.
b43097f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment