diff options
author | Rob Funk <rfunk@funknet.net> | 2004-06-18 06:55:28 +0000 |
---|---|---|
committer | Rob Funk <rfunk@funknet.net> | 2004-06-18 06:55:28 +0000 |
commit | 49b630f8ea30b7a5066f87b16b42cffec00a7bef (patch) | |
tree | 73a0831dd8a14ff248f883733478d3c3241759b1 | |
parent | 66ddc385acb6af3f9ffaa25ec0b2ff5e85967fac (diff) | |
download | fetchmail-49b630f8ea30b7a5066f87b16b42cffec00a7bef.tar.gz fetchmail-49b630f8ea30b7a5066f87b16b42cffec00a7bef.tar.bz2 fetchmail-49b630f8ea30b7a5066f87b16b42cffec00a7bef.zip |
Start converting release scripts over to new environment
svn path=/trunk/; revision=3894
-rw-r--r-- | Makefile.in | 19 | ||||
-rwxr-xr-x | growthplot | 38 | ||||
-rwxr-xr-x | listsize | 31 | ||||
-rwxr-xr-x | makerelease | 105 | ||||
-rwxr-xr-x | specgen.sh | 18 |
5 files changed, 130 insertions, 81 deletions
diff --git a/Makefile.in b/Makefile.in index 14cf0db5..3d38ed22 100644 --- a/Makefile.in +++ b/Makefile.in @@ -184,7 +184,7 @@ clean: -cd intl; $(MAKE) clean -rm -f $(top_builddir)/intl/libintl.h # work around GNU gettext brain-damage -cd po; $(MAKE) clean - -rm -f fetchmail *.o core fetchmail.dvi \ + -rm -f fetchmail *.o core *~ fetchmail.dvi \ rcfile_l.c rcfile_y.h rcfile_y.c \ fetchmail.tar fetchmail.tar.gz \ netrc rfc822 unmime fetchmail-man.html @@ -196,7 +196,8 @@ distclean: clean -cd intl; $(MAKE) distclean -cd po; $(MAKE) distclean -rm -f TAGS tags config.h config.log \ - config.cache stamp-h stamp-h.in # config.status Makefile + config.cache stamp-h stamp-h.in + -rm -f config.status Makefile realclean: distclean -rm -f FAQ FEATURES NOTES MANIFEST @@ -276,7 +277,7 @@ all = $(docs) $(config) $(srcs) $(parser) $(headers) $(extra) $(scripts) \ $(srcdir)/po/* $(srcdir)/intl $(srcdir)/beos/* ABOUT-NLS $(srcdir)/MANIFEST fetchmail.spec: Makefile.in - specgen.sh $(VERSION) >fetchmail.spec + $(srcdir)/specgen.sh $(VERSION) >fetchmail.spec MANIFEST: $(srcdir) Makefile.in @echo $(all) | tr "[ \t]" '\n' | sed -e '/^\.\//s///' | sort >MANIFEST @@ -303,20 +304,20 @@ TODO: todo.html # man2html no longer chokes and dies on this man page, # but manServer.pl does a much better job. fetchmail-man.html: fetchmail.man - manServer.pl fetchmail.man >fetchmail-man.html + PATH=\${PATH}:$(srcdir)/dist-tools manServer.pl fetchmail.man >fetchmail-man.html # Make distribution. -dist: distclean MANIFEST Makefile.in distdocs - touch fetchmail.lsm - make fetchmail-$(VERSION).tar.gz +dist: MANIFEST Makefile.in distdocs fetchmail-$(VERSION).tar.gz + #touch fetchmail.lsm + #make fetchmail-$(VERSION).tar.gz #-cd po; make update-po ls -l fetchmail-$(VERSION).tar.gz - @echo "Don't forget to build RPMs from root!" + #@echo "Don't forget to build RPMs from root!" # Firewall against the lossage in autoconf that keeps breaking our build. EX = --exclude "fetchmail-$(VERSION)/intl/libintl.h" fetchmail-$(VERSION).tar.gz: $(all) - (cd ..; ln -sf fetchmail fetchmail-$(VERSION)) + (cd ..; ln -sf $(shell basename \${PWD}) fetchmail-$(VERSION)) (cd ..; tar $(EX) -czf fetchmail-$(VERSION).tar.gz `sed <fetchmail-$(VERSION)/MANIFEST s:^:fetchmail-$(VERSION)/:`) mv -f ../fetchmail-$(VERSION).tar.gz . rm ../fetchmail-$(VERSION) @@ -3,20 +3,25 @@ # growthplot -- plot the fetchmail project's growth as a function of time # +PATH="$PATH:.:./dist-tools"; export PATH + +tmp=/tmp/fetchmail-growthplot.$$ +mkdir $tmp + # Get data from the NEWS file -timeseries >/tmp/growthplot$$ -grep "^[0-9]" /tmp/growthplot$$ >/tmp/growthnumbers$$ -grep "^[0-9.]*.[05].0 " /tmp/growthplot$$ >/tmp/growthmajors$$ -sed '/^4.2.9/,$d' </tmp/growthnumbers$$ >/tmp/growthannounce$$ +timeseries >$tmp/growthplot$$ +grep "^[0-9]" $tmp/growthplot$$ >$tmp/growthnumbers$$ +grep "^[0-9.]*.[05].0 " $tmp/growthplot$$ >$tmp/growthmajors$$ +sed '/^4.2.9/,$d' <$tmp/growthnumbers$$ >$tmp/growthannounce$$ # gnuplot line styles. These occasionally change (like beteween 3.5 and 3.7); -# use "echo "set terminal png color; test" | gnuplot | display - to check. +# use "echo 'set terminal png; test' | gnuplot | display -" to check. blue_boxes=3 green_crosses=2 cyan_diamonds=37 # Once purple triangles, but we can't do that anymore brown_triangles=23 -cat >/tmp/growthimage$$ <<EOF +cat >$tmp/growthimage$$ <<EOF set title "Fetchmail project growth history" set xlabel 'Days since baseline' set ylabel 'Participants' @@ -27,7 +32,7 @@ set tics out set autoscale y set y2range [5000:50000] set key bottom right box -set terminal png color +set terminal png EOF @@ -72,7 +77,7 @@ EOF lasttotal=$total fi done -) </tmp/growthplot$$ >>/tmp/growthimage$$ +) <$tmp/growthplot$$ >>$tmp/growthimage$$ # OK, now write the major-release labels ( @@ -81,22 +86,23 @@ EOF echo "set arrow from $days, $total - 55 to $days, $total - 15 head" echo "set label '$version' at $days - 5, $total - 65" done -) </tmp/growthmajors$$ >>/tmp/growthimage$$ +) <$tmp/growthmajors$$ >>$tmp/growthimage$$ -cat >>/tmp/growthimage$$ <<EOF -plot [] [0:] '/tmp/growthnumbers$$' using 6:5 \ +cat >>$tmp/growthimage$$ <<EOF +plot [] [0:] '$tmp/growthnumbers$$' using 6:5 \ title "Both lists" with points $blue_boxes, \ - '/tmp/growthannounce$$' using 6:4 \ + '$tmp/growthannounce$$' using 6:4 \ title "fetchmail-announce" with points $cyan_diamonds, \ - '/tmp/growthannounce$$' using 6:3 \ + '$tmp/growthannounce$$' using 6:3 \ title "fetchmail-friends" with points $green_crosses, \ - '/tmp/growthnumbers$$' using 6:2 axes x1y2 \ + '$tmp/growthnumbers$$' using 6:2 axes x1y2 \ title "Lines of code" with points $brown_triangles EOF -gnuplot /tmp/growthimage$$ >growth.png +gnuplot $tmp/growthimage$$ >growth.png -rm -f /tmp/growth* +rm -f $tmp/growth* +rmdir $tmp # growthplot ends here @@ -1,15 +1,36 @@ #!/bin/sh # # Mine list sizes from MailMan web interfaces +# +# * Must set environment variable FETCHMAIL_LIST_PASS to list admin password + +project="fetchmail" +admin="http://lists.berlios.de/mailman/admin" +adminpw=$FETCHMAIL_LIST_PASS -admin="http://lists.ccil.org/mailman/admin" list="$1" -tmp="/usr/tmp/listsize.$$" +if [ ! "$list" ]; then + echo "Usage: $0 list" 1>&2 + exit 1 +fi +case "$list" in +$project-*) + # already gave us the full name, e.g. fetchmail-announce + ;; +*) + # only gave us the last part of the name, e.g. announce + list="$project-$list" + ;; +esac +hexpw=`echo "$adminpw" | od -t x1 -w64 | sed -e 's/^[0-9]*//' -e '/^ *$/d' -e 's/ /%/g'` +umask 077 +tmp="/tmp/$project-$list.listsize.$$" # First get the login cookie... -curl -s -D $tmp $admin/fetchmail-${list}?adminpw=mypaswrd >/dev/null +curl -s -D "$tmp" "$admin/${list}?adminpw=$hexpw" >/dev/null # Second gets the actual stat -curl -s -b $tmp $admin/fetchmail-${list}/members \ - | sed -n '/.*>\([0-9][0-9]*\) members total.*/s//\1/p' +curl -s -b "$tmp" "$admin/${list}/members" \ + | sed -n '/.*>(\([0-9][0-9]*\) members total.*/s//\1/p' +rm -f "$tmp" # end diff --git a/makerelease b/makerelease index 37a2fe95..035ea012 100755 --- a/makerelease +++ b/makerelease @@ -4,11 +4,19 @@ # Dumps a release notice and diffs as a MIME multipart message # in RELEASE_NOTES # -$timezone = "-0500"; +use POSIX qw(strftime); +$timezone = strftime('%z', localtime) || "-0500"; +$tmp = $ENV{TMPDIR} || $ENV{TMP} || $ENV{TEMP} || "/tmp"; + +$project = "fetchmail"; +$svnrepos = "svn://svn.berlios.de/$project"; +$website = "http://developer.berlios.de/projects/$project"; +$mailfrom = "<$project-devel-owner\@lists.berlios.de> (Fetchmail Development Team)"; $diffs = 0; $verbose = 0; $null = ">/dev/null"; +$errnull = "2>/dev/null"; while ($i = shift @ARGV) { if ($i =~ /^(--diffs|-d)$/i) @@ -31,38 +39,39 @@ while ($i = shift @ARGV) $version=`grep 'VERSION *=' Makefile.in`; $version =~ /VERSION *= *(.*)/; $version = $1; -$rcsid = $version; -$rcsid =~ tr/./-/; +$tag = "RELEASE_$version"; +$tag =~ tr/./-/; -open(ID, "rlog -h NEWS|"); -while (<ID>) { - last if /^symbolic names/; -} +open(ID, "svn ls $svnrepos/tags|"); while (<ID>) { - if (/^\t(.*):/) { - push(@versions, $1); + if (m{^(RELEASE_.*)/}) { + unshift(@versions, $1); } } close(ID); -if ($versions[0] eq $rcsid) { - $rcsid = $versions[0]; - $oldid = $versions[1]; +if ($versions[0] eq $tag) { + $tag = $versions[0]; + $oldtag = $versions[1]; } else { - $rcsid = '<workfile>'; - $oldid = $versions[0]; + $tag = '<workfile>'; + $oldtag = $versions[0]; } -#$ENV{'PATH'} = "~esr/bin:/bin:/usr/bin"; +$ENV{PATH} .= ":./dist-tools:./dist-tools/shipper:."; -print "Building $version release, RCS ID $rcsid, previous RCS ID $oldid\n"; +print "Building $version release, tag $tag, previous tag $oldtag\n"; -if (system("./configure; make -C po update-po; make clean")) { - die("Failure in translation-file rebuild.") +if (system("aclocal && autoconf")) { + die("Failure in regenerating autoconf files\n"); +} + +if (system("./configure && make clean && make -C po update-po && make clean")) { + die("Failure in translation-file rebuild\n"); } print "### Test-building the software...\n"; -if (system("configure --disable-nls; make")) { +if (system("./configure --disable-nls && make clean && make")) { die("Compilation failure\n"); } @@ -72,23 +81,21 @@ if (system("make dist $null")) { } print "### Building the RPMs...\n"; -if (system("buildrpms fetchmail-${version}.tar.gz $null")) { +if (system("buildrpms $project-${version}.tar.gz $null")) { die("RPM-build failure\n"); } -open(REPORT, ">PREAMBLE.$$"); +open(REPORT, ">$tmp/$project.PREAMBLE.$$"); print REPORT <<EOF; -From: esr\@thyrsus.com (Eric S. Raymond) -Reply-To: esr\@thyrsus.com (Eric S. Raymond) -Subject: The $version release of fetchmail is available -FCC: ~/postings/outmail +From: $mailfrom +Subject: The $version release of $project is available -The $version release of fetchmail is now available at the usual locations, -including <URL:http://$ENV{'WWWVIRTUAL'}/~esr/fetchmail>. +The $version release of $project is now available at the usual locations, +including <URL:$website>. The source archive is available at: -<URL:http://$ENV{'WWWVIRTUAL'}/~esr/fetchmail/fetchmail-${version}.tar.gz> +<URL:$website/$project-${version}.tar.gz> Here are the release notes: @@ -97,23 +104,24 @@ EOF # Extract the current notes open(NEWS, "NEWS"); while (<NEWS>) { - if (/^fetchmail/) { + if (/^$project/) { print REPORT $_; last; } } while (<NEWS>) { - if (/^fetchmail/) { + if (/^$project/) { last; } print REPORT $_; } -$oldrcs = $oldid; -$oldrcs =~ tr/-/./; +$oldver = $oldtag; +$oldver =~ tr/-/./; +$oldver =~ s/^RELEASE_//; if ($diffs) { - print REPORT "Diffs from the previous ($oldrcs) release follow as a MIME attachment." + print REPORT "Diffs from the previous ($oldver) release follow as a MIME attachment." } else { print REPORT "By popular demand, diffs from the previous release have been omitted." } @@ -122,33 +130,38 @@ close(NEWS); close(REPORT); -if ($rcsid eq '<workfile>') { - system("rcsdiff -u -r$oldid RCS/* 2>/dev/null >DIFFS.$$"); +if ($tag eq '<workfile>') { + system("svn diff -r$oldtag $errnull >$tmp/$project.DIFFS.$$"); } else { - system("rcsdiff -u -r$oldid -r$rcsid RCS/* 2>/dev/null >DIFFS.$$"); + system("svn diff -r$oldtag -r$tag $errnull >$tmp/$project.DIFFS.$$"); } print "Diff size:"; -system("wc <DIFFS.$$"); +system("wc <$tmp/$project.DIFFS.$$"); if ($diffs) { - system "metasend -b -D 'fetchmail-$rcsid announcement' -m 'text/plain' -e 7bit -f PREAMBLE.$$ -n -D 'diff -u between -$oldrcs $rcsid' -m 'text/plain' -e 7bit -f DIFFS.$$ -o ANNOUNCE.EMAIL"; + system "metasend -b" + ." -D '$project-$tag announcement' -m 'text/plain' -e 7bit -f $tmp/$project.PREAMBLE.$$" + ." -n -D 'diff between $oldver and $version' -m 'text/plain' -e 7bit -f $tmp/$project.DIFFS.$$" + ." -o ANNOUNCE.EMAIL"; } else { - rename("PREAMBLE.$$", "ANNOUNCE.EMAIL"); + rename("$tmp/$project.PREAMBLE.$$", "ANNOUNCE.EMAIL"); } -system("chown esr ANNOUNCE.EMAIL"); -chmod(0700, "ANNOUNCE.EMAIL"); +#system("chown esr ANNOUNCE.EMAIL"); +#chmod(0700, "ANNOUNCE.EMAIL"); -#unlink("PREAMBLE.$$"); -unlink("DIFFS.$$"); +#unlink("$tmp/$project.PREAMBLE.$$"); +unlink("$tmp/$project.DIFFS.$$"); print "Building index page...\n"; system("rm -f index.html; indexgen.sh"); -print "Building test server list...\n"; -system("rm -f testservers.html; testservers-gen.sh >testservers.html"); +if (-r "testsites") { + print "Building test server list...\n"; + system("rm -f testservers.html; testservers-gen.sh >testservers.html"); +} print "Making activity graph..."; -growthplot; +system "growthplot"; print "Done\n"; @@ -1,11 +1,19 @@ +#!/bin/sh + +user=`whoami` +name=`grep "^${user}:" /etc/passwd | cut -d: -f5|sed -e 's/^.*,//'` +domain=mail.berlios.de +email="$user@$domain" +packager="$name <$email>" + cat <<EOF # Note: Do not hack fetchmail.spec by hand -- it's generated by specgen.sh Name: fetchmail Version: $1 Release: 1 -Vendor: Eric Conspiracy Secret Labs -Packager: Eric S. Raymond <esr@thyrsus.com> -URL: http://www.catb.org/~esr/fetchmail/ +Vendor: The Community Fetchmail Project +Packager: $packager +URL: http://developer.berlios.de/projects/fetchmail Source: %{name}-%{version}.tar.gz Group: Applications/Mail Group(pt_BR): Aplicações/Correio Eletrônico @@ -23,7 +31,7 @@ Summary(tr): POP2, POP3, APOP, IMAP protokolleri ile uzaktan mektup alma yazý Summary(da): Alsidig POP/IMAP post-afhentnings dæmon BuildRoot: %{_tmppath}/%{name}-root #Keywords: mail, client, POP, POP2, POP3, APOP, RPOP, KPOP, IMAP, ETRN, ODMR, SMTP, ESMTP, GSSAPI, RPA, NTLM, CRAM-MD5, SASL -#Destinations: fetchmail-friends@ccil.org, fetchmail-announce@ccil.org +#Destinations: fetchmail-users@lists.berlios.de, fetchmail-announce@lists.berlios.de %description Fetchmail is a free, full-featured, robust, and well-documented remote @@ -155,6 +163,6 @@ rm -rf \$RPM_BUILD_ROOT /usr/lib/rhs/control-panel/fetchmailconf.init %changelog -* `date '+%a %b %d %Y'` <esr@thyrsus.com> ${version} +* `date '+%a %b %d %Y'` <$email> ${version} - See the project news file for recent changes. EOF |