Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

80 linhas
1.5KB

  1. #!/bin/sh
  2. package='tufte-latex'
  3. class='tufte-handout.cls'
  4. set -e
  5. if test $# -ne 1; then
  6. echo "usage: $0 VERSION"
  7. exit 1
  8. fi
  9. version=$1
  10. if ! echo $version | grep -E "^[0-9]+\.[0-9]+\.[0-9]+$"
  11. then
  12. echo "VERSION should be of the form 1.2.5 (major.minor.revision)"
  13. exit 1
  14. fi
  15. if ! grep -q $version $class
  16. then
  17. echo "Error: version skew. '$version' does not match that in class"
  18. grep -H ProvidesClass $class
  19. exit 1
  20. fi
  21. date=`date +%Y/%m/%d`
  22. if ! grep -q $date $class
  23. then
  24. echo "Error: date skew. '$date' does not match that in class"
  25. grep -H ProvidesClass $class
  26. exit 1
  27. fi
  28. if ! grep -q $version History.txt
  29. then
  30. echo "Error: no release notes for '$version' found in History.txt"
  31. grep -H $version History.txt
  32. exit 1
  33. fi
  34. history_date=`date +%Y-%m-%d`
  35. if ! grep -q $history_date History.txt
  36. then
  37. echo "Error: '$history_date' not found in History.txt"
  38. grep -H $history_date History.txt
  39. exit 1
  40. fi
  41. # Refresh sample document
  42. pdflatex sample-handout > refresh-sample.log
  43. rm -f sample-handout.{aux,log,out} refresh-sample.log
  44. # Make bundle
  45. mkdir -p pkg/$package-$version
  46. tar cf - `cat Manifest.txt` | ( cd pkg/$package-$version && tar xf - )
  47. zip -rq pkg/$package-$version.zip pkg/$package-$version
  48. cat << MESSAGE
  49. `openssl dgst -sha1 pkg/$package-$version.zip`
  50. Don't forget to tag,
  51. svn cp -m'To tag release $version.' \\
  52. https://$package.googlecode.com/svn/trunk \\
  53. https://$package.googlecode.com/svn/tags/rel_$version
  54. and upload,
  55. http://code.google.com/p/$package/downloads/list
  56. http://ctan.org/upload
  57. MESSAGE