Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(769)

Issue 11825019: a utility script to pngcrush png files (Closed)

Created:
7 years, 11 months ago by oshima
Modified:
7 years, 11 months ago
Reviewers:
stevenjb, Nico, jrbarnette
CC:
chromium-reviews, msw
Visibility:
Public.

Description

a utility script to pngcrush png files BUG=150046 TEST=none NOTRY=true Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=176157

Patch Set 1 : #

Patch Set 2 : #

Total comments: 7

Patch Set 3 : #

Patch Set 4 : fix trap #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+62 lines, -0 lines) Patch
A build/sanitize-png-files.sh View 1 2 3 1 chunk +62 lines, -0 lines 2 comments Download

Messages

Total messages: 13 (0 generated)
oshima
would you mind take a look at this?
7 years, 11 months ago (2013-01-09 18:22:20 UTC) #1
stevenjb
lgtm, but my shell fu is pretty weak. +jrbarnette@
7 years, 11 months ago (2013-01-09 18:40:39 UTC) #2
jrbarnette
On 2013/01/09 18:40:39, stevenjb (chromium) wrote: > lgtm, but my shell fu is pretty weak. ...
7 years, 11 months ago (2013-01-09 19:15:37 UTC) #3
oshima
On 2013/01/09 19:15:37, jrbarnette wrote: > On 2013/01/09 18:40:39, stevenjb (chromium) wrote: > > lgtm, ...
7 years, 11 months ago (2013-01-09 20:04:37 UTC) #4
jrbarnette
<sigh> I've gotten used to Gerrit; didn't realize I hadn't published my drafts w/ the ...
7 years, 11 months ago (2013-01-09 20:44:19 UTC) #5
oshima
https://codereview.chromium.org/11825019/diff/4001/build/sanitize-png-files.sh File build/sanitize-png-files.sh (right): https://codereview.chromium.org/11825019/diff/4001/build/sanitize-png-files.sh#newcode29 build/sanitize-png-files.sh:29: for f in `find $dir -name "*.png"`; do On ...
7 years, 11 months ago (2013-01-10 05:36:34 UTC) #6
jrbarnette
LGTM https://codereview.chromium.org/11825019/diff/4001/build/sanitize-png-files.sh File build/sanitize-png-files.sh (right): https://codereview.chromium.org/11825019/diff/4001/build/sanitize-png-files.sh#newcode51 build/sanitize-png-files.sh:51: trap "rm -rf $TMP_DIR; exit 255" SIGINT SIGTERM ...
7 years, 11 months ago (2013-01-10 18:34:33 UTC) #7
oshima
On 2013/01/10 18:34:33, jrbarnette wrote: > LGTM > > https://codereview.chromium.org/11825019/diff/4001/build/sanitize-png-files.sh > File build/sanitize-png-files.sh (right): > ...
7 years, 11 months ago (2013-01-10 20:49:56 UTC) #8
jrbarnette
On 2013/01/10 20:49:56, oshima wrote: [ ... ] > I think I misunderstood the behavior ...
7 years, 11 months ago (2013-01-10 20:53:09 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/oshima@chromium.org/11825019/7002
7 years, 11 months ago (2013-01-10 21:14:21 UTC) #10
commit-bot: I haz the power
Change committed as 176157
7 years, 11 months ago (2013-01-10 21:20:05 UTC) #11
Nico
Nice!! https://chromiumcodereview.appspot.com/11825019/diff/7002/build/sanitize-png-files.sh File build/sanitize-png-files.sh (right): https://chromiumcodereview.appspot.com/11825019/diff/7002/build/sanitize-png-files.sh#newcode23 build/sanitize-png-files.sh:23: -rem mkTS $file > /dev/null I asked leiz/msw ...
7 years, 11 months ago (2013-01-10 23:47:37 UTC) #12
oshima
7 years, 11 months ago (2013-01-11 00:12:11 UTC) #13
Message was sent while issue was closed.
https://chromiumcodereview.appspot.com/11825019/diff/7002/build/sanitize-png-...
File build/sanitize-png-files.sh (right):

https://chromiumcodereview.appspot.com/11825019/diff/7002/build/sanitize-png-...
build/sanitize-png-files.sh:23: -rem mkTS $file > /dev/null
On 2013/01/10 23:47:37, Nico wrote:
> I asked leiz/msw about the best way to crunch PNG files, and he wrote:
> 
> """PNGCrush alone isn't ideal. You'll also want to strip iTXt, tEXt, zTXt, and
> tIME
> chunks *and run PNGSlim* for non-trivial additional lossless size reduction.
> I've been meaning to write up these instructions for a while, but you can get
> the gist from:
> 
> crbug.com/76282 and codereview.chromium.org/7782022 and cmd:
> pngcrush.exe -reduce -brute -rem iTXt -rem tEXt -rem zTXt -rem tIME"""
> 
> It looks like you are not using all these flags. Also, the bug mentioned also
> running pngslim.

I took the command from chrome/app/theme/README but looks like it wasn't up to
date.
I'll fix them in follow up CL.

> Finally, should this be a python script, so that windows people can run it? Or
> is this supposed to run automatically on some bot?

I was planning to just run this periodically for the time being.
I'd rather want to automate someone and will look into it first. IIRC, there
was some discussion about it and decided not to, but I'll look into it again.

Powered by Google App Engine
This is Rietveld 408576698