]> code.delx.au - gnu-emacs-elpa/blob - admin/org-synch.sh
* admin/archive-contents.el (batch-make-site-dir, archive--write-pkg-file): New funct...
[gnu-emacs-elpa] / admin / org-synch.sh
1 #!/bin/sh
2
3 # this script expects $1 to be the download directory and $2 to have org-synch.el
4
5 PATH="/bin:/usr/bin:/usr/local/bin:${PATH}"
6
7 pkgname=`curl -s http://orgmode.org/pkg/daily/|perl -ne 'push @f, $1 if m/(org-\d{8}\.tar)/; END { @f = sort @f; print "$f[-1]\n"}'`
8
9 cd $1
10 wget -q http://orgmode.org/pkg/daily/${pkgname} -O ${pkgname}-tmp
11 if [ -f ${pkgname}-tmp ]; then
12 rm -f org*.tar
13 mv ${pkgname}-tmp ${pkgname} && \
14 emacs -batch -l $2/org-synch.el --eval "(org-synch \"${pkgname}\")"
15 fi