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

Unified Diff: scripts/bitmaps/make_bmp_images.sh

Issue 3302005: Reposition text and URL (Closed) Base URL: http://git.chromium.org/git/vboot_reference.git
Patch Set: Created 10 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | scripts/bitmaps/originals/DeveloperBmp.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/bitmaps/make_bmp_images.sh
diff --git a/scripts/bitmaps/make_bmp_images.sh b/scripts/bitmaps/make_bmp_images.sh
index 84173c1ffe59cf2533c4c7fe105a3e03665d8c15..3a163c1d596005f7642457dd8c34ca24607ad4a5 100755
--- a/scripts/bitmaps/make_bmp_images.sh
+++ b/scripts/bitmaps/make_bmp_images.sh
@@ -83,16 +83,16 @@ function process_one_file {
if [ -r "$txt_file" ]; then
# Replace all '$URL' in the URL in the text file with the real url
perl -p \
- -e 'BEGIN {$/ = ""; $url = shift; }' \
- -e 'chomp; s/\$URL/$url/gse;' \
- -e 'END {print "\n";}' "$url" "$txt_file" > "$label_file"
+ -e 'BEGIN {$/ = undef; $url = shift; }' \
+ -e 's/\s+$/\n/gs; s/\$URL/$url/gs;' \
+ "$url" "$txt_file" > "$label_file"
# Render it
convert "$img_crop_a" -fill white \
-font "$font" -pointsize "$pointsize" -interline-spacing 5 \
- -gravity south -annotate '+0+10' '@'"$label_file" "$img_txt_a"
+ -gravity south -annotate '+0+0' '@'"$label_file" "$img_txt_a"
convert "$img_crop_b" -fill white \
-font "$font" -pointsize "$pointsize" -interline-spacing 5 \
- -gravity south -annotate '+0+10' '@'"$label_file" "$img_txt_b"
+ -gravity south -annotate '+0+0' '@'"$label_file" "$img_txt_b"
else
mv "$img_crop_a" "$img_txt_a"
mv "$img_crop_b" "$img_txt_b"
@@ -110,5 +110,6 @@ for file in originals/*.gif; do
done
# Zip up the bitmaps
-(cd "$outdir_a" && zip -qr "${thisdir}/out_${geom_crop_a}.zip" *)
-(cd "$outdir_b" && zip -qr "${thisdir}/out_${geom_crop_b}.zip" *)
+nicename=${url// /_}
+(cd "$outdir_a" && zip -qr "${thisdir}/out_${nicename}__${geom_crop_a}.zip" *)
+(cd "$outdir_b" && zip -qr "${thisdir}/out_${nicename}__${geom_crop_b}.zip" *)
« no previous file with comments | « no previous file | scripts/bitmaps/originals/DeveloperBmp.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698