]>
code.delx.au - gnu-emacs-elpa/blob - admin/update-archive.sh
9 makelog
="$(pwd)/make.log"
14 # Send an email to warn about a problem.
17 if [ "" = "$makelog" ]; then
20 mx_gnu_org
="$(host -t mx gnu.org | sed 's/.*[ ]//')"
21 (sleep 5; echo "HELO elpa.gnu.org"
22 sleep 1; echo "MAIL FROM: <elpa@elpa.gnu.org>"
23 sleep 1; echo "RCPT TO: <emacs-elpa-diffs@gnu.org>"
26 From: ELPA update <elpa@elpa.gnu.org>
27 To: emacs-elpa-diffs@gnu.org
32 echo "."; sleep 1) |
telnet "$mx_gnu_org" smtp
41 git pull || signal_error
"git pull failed"
43 # Remember we're inside the "elpa" branch which we don't want to trust,
44 # So always refer to the makefile and admins files from $builddir".
46 # Setup and update externals.
47 emacs
--batch -l "$buildir/admin/archive-contents.el" \
48 -f archive-add
/remove
/update-externals
50 make -f "$buildir/GNUmakefile" check_copyrights ||
51 signal_error
"check_copyright failed"
55 rsync
-av --delete --exclude=ChangeLog
--exclude=.git ..
/elpa
/packages .
/
57 # Refresh the ChangeLog files. This needs to be done in
58 # the source tree, because it needs the VCS data!
59 emacs
-batch -l admin
/archive-contents.el \
60 -eval '(archive-prepare-packages "../elpa")'
63 rm -rf archive
# In case there's one left over!
64 make archive-full ||
{
65 signal_error
"make archive-full failed"
67 latest
="emacs-packages-latest.tgz"
69 tar zcf
"$latest" packages
)
71 mkdir
-p staging
/packages
72 # Not sure why we have `staging-old', but let's keep it for now.
74 cp -a staging staging-old
75 # Move new files into place but don't throw out old package versions.
76 for f
in build
/archive
/packages
/*; do
77 dst
="staging/packages/$(basename "$f")"
78 # Actually, let's never overwrite an existing version. So changes can
79 # be installed without causing a new package to be built until the
80 # version field is changed. Some files need to be excluded from the
81 # "immutable" policy, most importantly "archive-contents"
84 */archive-contents |
*-readme.txt
) mv "$f" "$dst" ;;
88 # FIXME: Announce the new package/version on
94 mv build
/archive
/"$latest" staging
/
97 # Make the HTML and readme.txt files.
98 (cd ..
/staging
/packages
99 emacs
--batch -l ..
/..
/build
/admin
/archive-contents.el \
100 --eval '(batch-html-make-index)')