hgbook

changeset 663:605af0a90e3e

Minor fix
author Dongsheng Song <songdongsheng@live.cn>
date Tue Mar 31 11:51:13 2009 +0800 (2009-03-31)
parents bc9dc4f2f912
children 4dd63ae7ba87
files Makefile contrib/hg-package
line diff
     1.1 --- a/Makefile	Tue Mar 31 11:11:43 2009 +0800
     1.2 +++ b/Makefile	Tue Mar 31 11:51:13 2009 +0800
     1.3 @@ -159,7 +159,7 @@
     1.4  	mkdir -p build/$(LINGUA)/source/figs
     1.5  	cp en/figs/*.png build/$(LINGUA)/source/figs
     1.6  	cp stylesheets/hgbook.css build/$(LINGUA)/source
     1.7 -	$(TRANSLATE) -m build/en/source/hgbook.xml -p po/$(LINGUA).po -l $@.tmp
     1.8 +	$(TRANSLATE) -m build/en/source/hgbook.xml.tmp -p po/$(LINGUA).po -l $@.tmp
     1.9  	cat $@.tmp | sed 's/\$$rev_id\$$/${rev_id}/' > $@
    1.10  endif
    1.11  
     2.1 --- a/contrib/hg-package	Tue Mar 31 11:11:43 2009 +0800
     2.2 +++ b/contrib/hg-package	Tue Mar 31 11:51:13 2009 +0800
     2.3 @@ -27,12 +27,19 @@
     2.4       cp pdf/hgbook.pdf ../hgbook-${l}-${rev_id}.pdf
     2.5       gzip -f9 ../hgbook-${l}-${rev_id}.pdf
     2.6    fi
     2.7 +
     2.8 +  if [ -f "epub/hgbook.epub" ] ; then
     2.9 +     cp epub/hgbook.epub ../hgbook-${l}-${rev_id}.epub
    2.10 +  fi
    2.11    )
    2.12  done
    2.13  
    2.14  upload_pass=$1
    2.15  upload_user=$2
    2.16  
    2.17 +# echo "upload_pass: ${upload_pass}"
    2.18 +# echo "upload_user: ${upload_user}"
    2.19 +
    2.20  if [ "${upload_user}x" == "x" ]; then
    2.21    upload_user="dongsheng.song"
    2.22  fi
    2.23 @@ -46,17 +53,24 @@
    2.24    fi
    2.25  
    2.26    for l in en zh; do
    2.27 +    if [ -f "hgbook-${l}-${rev_id}.epub" ] ; then
    2.28 +      python googlecode_upload.py --user="${upload_user}" --password="${upload_pass}" \
    2.29 +          -p "i18n-zh" -l "Type-Docs,book,hgbook,hg,mercurial,ebook" \
    2.30 +          -s "Distributed revision control with Mercurial - ${l} - ePub" \
    2.31 +          hgbook-${l}-${rev_id}.epub
    2.32 +    fi
    2.33 +
    2.34      if [ -f "hgbook-${l}-${rev_id}.pdf.gz" ] ; then
    2.35 -      python googlecode_upload.py -u "dongsheng.song" -w "$1" \
    2.36 -          -p "i18n-zh" -l "Type-Docs,hgbook" \
    2.37 +      python googlecode_upload.py --user="${upload_user}" --password="${upload_pass}" \
    2.38 +          -p "i18n-zh" -l "Type-Docs,book,hgbook,hg,mercurial" \
    2.39            -s "Distributed revision control with Mercurial - ${l} - pdf" \
    2.40            hgbook-${l}-${rev_id}.pdf.gz
    2.41      fi
    2.42  
    2.43      for f in html html-single; do
    2.44 -      if [ -f "hgbook-${l}-${rev_id}.pdf.gz" ] ; then
    2.45 -        python googlecode_upload.py -u "dongsheng.song" -w "$1" \
    2.46 -            -p "i18n-zh" -l "Type-Docs,hgbook" \
    2.47 +      if [ -f "hgbook-${l}-${f}-${rev_id}.tar.gz" ] ; then
    2.48 +        python googlecode_upload.py --user="${upload_user}" --password="${upload_pass}" \
    2.49 +            -p "i18n-zh" -l "Type-Docs,book,hgbook,hg,mercurial" \
    2.50              -s "Distributed revision control with Mercurial - ${l} - ${f}" \
    2.51              hgbook-${l}-${f}-${rev_id}.tar.gz
    2.52        fi