Page MenuHomePhabricator

Detect or manage optipng versions (-clobber flag)
Closed, WontfixPublic

Description

The -clobber option was removed in a more recent version of optipng. optipng 0.6.4 is available in Ubuntu 12.04 and CentOS 6.4 and there isn't any check for what version is installed on the system. See comment-2 for corrections.

Writing CSS 'webroot/rsrc/css/sprite-apps.css'...
Writing sprite 'webroot/rsrc/image/sprite-apps.png'...
Optimizing...
Error: Unrecognized option: -clobber
Writing sprite 'webroot/rsrc/image/sprite-apps-X2.png'...
Optimizing...
Error: Unrecognized option: -clobber
Writing CSS 'webroot/rsrc/css/sprite-apps-large.css'...
Writing sprite 'webroot/rsrc/image/sprite-apps-large.png'...
Optimizing...
Error: Unrecognized option: -clobber
Writing sprite 'webroot/rsrc/image/sprite-apps-large-X2.png'...
Optimizing...
Error: Unrecognized option: -clobber
Done.

Event Timeline

nmalcolm triaged this task as Normal priority.Jun 4 2013, 2:44 AM
nmalcolm added a project: Celerity.
nmalcolm updated the task description. (Show Details)
nmalcolm added a subscriber: nmalcolm.

Looking closer, the manual states "This option, which has no effect, is deprecated and will be removed eventually.".

I don't think "-clobber" has been removed -- it was added in v0.7:

http://optipng.sourceforge.net/history.txt

It looks like it was made default in the current development version (so it has no effect, and is disabled with -no-clobber). Between 0.7 and the unreleased version, it does have an effect.

It should work if you upgrade to v0.7 or newer. At some point we should probably do a version check or manually implement -clobber by moving files around to avoid this, but these aren't priorities since normal users aren't generally expected to run this script.

I think the manual may have confused me. It seemed like it was a legacy command. :)

epriestley renamed this task from generate_sprites.php produces errors with optipng 0.6.4 to Detect or manage optipng versions (-clobber flag).Jun 6 2013, 3:41 PM
epriestley lowered the priority of this task from Normal to Wishlist.
epriestley claimed this task.

This hasn't come up again in three years so I'm just going to assume that everyone is realistically installing 0.7.0 or newer nowadays. Today, optiping strongly recommends upgrading to 0.7.6 or newer to fix some security issues.

Beyond that, we've decreased our use of spriting, and usually for the best:

  • We now use data URIs for many small images.
  • We now use an icon font (FontAwesome) for icons.
  • Some stuff has generally become less spritable because it is modular and third-parties can add new stuff, so we're less able to ship with a sprite.
  • In the future, we plan to consider extending non-sprite image resource capabilities (see T11217, for example), so this trend away from sprites will probably continue.

It's possible we'll even remove spriting completely after tokens, since I think the last sprite beyond that is login, which is modular, does not benefit much from being sprited, and can probably be data-URI'd anyway.

chad changed the visibility from "All Users" to "Public (No Login Required)".Aug 23 2016, 6:46 PM
chad added a subscriber: chad.

I'm on 14.04 and it has 0.6.4 installed. :(

do-dist-upgrade is pushing me to 16.04

is there a twitch module for bash? can I live stream this excitement?

Sounds like we should write a "Screencastph" app!