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

Non-digest only mode (move instead of copy) #44

Open
abrom opened this issue Dec 7, 2016 · 4 comments
Open

Non-digest only mode (move instead of copy) #44

abrom opened this issue Dec 7, 2016 · 4 comments

Comments

@abrom
Copy link

abrom commented Dec 7, 2016

For various reasons we've gone for a setup where cache busting is provided at a higher level (root of the path) so digesting of any sort isn't useful (actually just gets in the way). Using this gem solves the problem but leaves our asset bundle double the size it really needs to be.

I'm going to patch a fork to include a non_digest_asset_mode or similar setting. Default being copy but optionally move.

Would this be something you'd be interested in?

@abrom abrom changed the title Non-digest only (move instead of copy) Non-digest only mode (move instead of copy) Dec 7, 2016
@courtland
Copy link

I'm just a non-stupid-digest-assets user, but I imagine moving the digested assets completely would break most applications. Perhaps adding a mode for copy, move, or symlink would be useful? I forget the disadvantages of symlink over copy in this situation but if I recall there are some other than the obvious bonus of not duplicating files.

@abrom
Copy link
Author

abrom commented Dec 7, 2016

@courtland the proposed change would definitely keep the status quo by default (see my note about the default being copy). You'd need to opt-in to change that to move (or something else).

Here's what I'm proposing master...abrom:master

along with

NonStupidDigestAssets.destupidify_mode = :move

will move instead of copy.

@alexspeller
Copy link
Owner

A PR for this sounds good to me, I wouldn't use it personally but I can see it might be useful

@mvz
Copy link

mvz commented Jun 12, 2018

I think you can just set config.assets.digest = false if you don't want digests at all.

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

No branches or pull requests

4 participants