projects
/
sh-gallery.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add disqus support
[sh-gallery.git]
/
jpg2html.sh
diff --git
a/jpg2html.sh
b/jpg2html.sh
index 0fcb14799aabe844d7751cc14a25ed97a08d2ea2..e826dfc73a90e62246be6992145e70150fd3412f 100755
(executable)
--- a/
jpg2html.sh
+++ b/
jpg2html.sh
@@
-21,6
+21,8
@@
for i in `seq 1 $len `; do
printf "<a href=\"../%s.html\">next</a>\n" $bn_next >> tmp
fi
printf "<a href=\"../%s.html\">next</a>\n" $bn_next >> tmp
fi
+ printf " %s/%s\n" $i $len >> tmp
+
this=$files[$i];
bn_this=${this/.jpg/}
printf "<a href=\"%s\"><img src=\"%s_thumb.jpg\" /></a>\n" $bn_this.html $bn_this >> all.tmp
this=$files[$i];
bn_this=${this/.jpg/}
printf "<a href=\"%s\"><img src=\"%s_thumb.jpg\" /></a>\n" $bn_this.html $bn_this >> all.tmp
@@
-33,9
+35,12
@@
for i in `seq 1 $len `; do
cat $bn_this.desc >> tmp
fi
cat $bn_this.desc >> tmp
fi
- cat tmpl_h.html tmp tmpl_f.html > $bn_this.html
+ rg="s/13371337/`basename $bn_this`/g"
+ (cat tmpl_h.html tmp; sed -e $rg tmpl_f.html) > $bn_this.html
rm tmp
done
rm tmp
done
-cat tmpl_h.html all.tmp tmpl_f.html > index.html
+printf "<br /><br />download: <a href=\"big.zip\">hi-res</a>, <a href=\"small.zip\">lo-res</a>\n" >> all.tmp
+
+(cat tmpl_h.html all.tmp; sed -e s/13371337/dreadcutmain/g tmpl_f.html) > index.html
rm all.tmp
rm all.tmp