]> code.delx.au - gnu-emacs-elpa/blobdiff - admin/org-synch.sh
* admin/package-update.sh: Disable org-mode fetch by default. Add
[gnu-emacs-elpa] / admin / org-synch.sh
index 45000b8f50b7044c59e492d198b23d7a6d49f057..79c551b66c1b5176fe867ba8a788c7e854ebdfb7 100755 (executable)
@@ -2,12 +2,14 @@
 
 # this script expects $1 to be the download directory and $2 to have org-synch.el
 
-pkgname=`/usr/bin/curl -s http://orgmode.org/pkg/daily/|/usr/bin/perl -ne 'push @f, $1 if m/(org-\d{8}\.tar)/; END { @f = sort @f; print "$f[-1]\n"}'`
+PATH=/bin:/usr/bin:/usr/local/bin
+
+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"}'`
 
 cd $1
-/usr/bin/wget -q http://orgmode.org/pkg/daily/$pkgname -O ${pkgname}-tmp
+wget -q http://orgmode.org/pkg/daily/${pkgname} -O ${pkgname}-tmp
 if [ -f ${pkgname}-tmp ]; then
-    /bin/rm -f org*.tar
-    /bin/mv ${pkgname}-tmp $pkgname && \
-    /usr/bin/emacs -batch -l $2/org-synch.el -f org-synch
+    rm -f org*.tar
+    mv ${pkgname}-tmp ${pkgname} && \
+    emacs -batch -l $2/org-synch.el --eval "(org-synch \"${pkgname}\")"
 fi