diff options
author | Karl Berry <karl@freefriends.org> | 2023-03-21 22:49:40 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2023-03-21 22:49:40 +0000 |
commit | 50a995b653ee3d8959f2418fa36f572c350fb462 (patch) | |
tree | d7b0d03d76b1fac11570f99f0aa4e63f474d7091 | |
parent | efcb20768a3c4b10e9be95c3a38cdf96e6859a63 (diff) |
clean up c2a, update release doc for 2023
git-svn-id: svn://tug.org/texlive/trunk@66642 c570f23f-e606-0410-a88d-b1316a301751
-rwxr-xr-x | Master/tlpkg/bin/c2a | 88 | ||||
-rw-r--r-- | Master/tlpkg/doc/releng.txt | 56 |
2 files changed, 88 insertions, 56 deletions
diff --git a/Master/tlpkg/bin/c2a b/Master/tlpkg/bin/c2a index 8b4194b0138..d684c4dfceb 100755 --- a/Master/tlpkg/bin/c2a +++ b/Master/tlpkg/bin/c2a @@ -2,44 +2,59 @@ # $Id$ # Public domain. Originally written by Karl Berry, 2022. # -# Update from CTAN to TL. First, run the test import with c2l; then, if -# no files were added or removed (and it was an existing package), -# automatically run c2l -p to "place" the new package in svn. -# Do not run svn commit. (Code needs to be refactored for common calls.) +# Top-level script to update from CTAN to TL. +# +# First (unless placing was explicitly specified with [-]p), +# run a test import with c2l. +# Then, if no files were added or removed (and it was an existing +# package), or if placing was explicitly specified, automatically run +# c2l p to "place" the new package in svn with adds/removes. +# Do not run svn commit. +# +# By the way, we accept "p" as well as "-p" because it's convenient for +# word deletion on the command line not to have a - lying around. For +# the same reason, the [-]p is given after the package, so we can +# add/remove it without having to edit the package name. Since we run +# this command multiple times a day, must optimize every keystroke. use strict; use warnings; (my $prg = $0) =~ s,.*/,,; -my $place_branch = 0; -#my $chicken = ""; -my $chicken = "-p"; - exit (&main ()); sub main { - die "Usage: $0 PKGNAME [-][p]\n" if (@ARGV == 0 || @ARGV > 2); + die "Usage: $0 PKGNAME [-][p]\n" if (@ARGV == 0 || @ARGV > 2); # USTL + my $status = 1; # default to failure + my $place = 0; if ($ARGV[$#ARGV] =~ /^-?p$/) { pop (@ARGV); $place = 1; } + + if ($place) { + $status = &do_place ("$prg: p(lace) explicitly given"); + exit $status; + } + + # no explicit place, run c2l to check if we can do it implicitly. printf "$prg: running c2l..."; - my @lines = `set -o pipefail; c2l @ARGV </dev/null 2>&1 | tee /tmp/c2l.out`; - if ($?) { + my @lines; + ($status,@lines) = &run_c2l (""); + if ($status) { print "first c2l failed, exiting.\n"; print @lines; - exit $?; + exit $status; } - my $status = 1; my $i; for ($i = 0; $i < @lines; $i++) { if ($lines[$i] =~ /^current vs.\ new/) { my $nextline = $lines[$i+1]; if ($nextline =~ /^[0-9]+ common files, ([0-9]+) changed/) { if ($1 == 0) { - print "seems nothing changed, done.\n"; + print "seems nothing has changed, done.\n"; print @lines; $status = 0; last; @@ -61,42 +76,37 @@ sub main { } if ($i == @lines) { - if ($place) { - $status = &do_place ("no current vs. new, but p(lace) given"); - } else { - print "no current vs. new, exiting.\n"; # new package, presumably - print @lines; - } + print "no current vs. new, exiting.\n"; # new package, presumably + print @lines; } return $status; } +# Run c2l to "place" (svn add/remove, but not commit) file. +# Return exit status. +# sub do_place { - my ($desc,$c2cmd) = @_; + my ($desc) = @_; - my $msg; - if ($c2cmd && $c2cmd eq "c2b") { - $msg = "$prg: $desc"; # place on branch - } else { - $c2cmd = "c2l"; - my $branch_msg = $place_branch ? "(+branch)" : ""; - $msg = "$desc, rerunning for svn$branch_msg..."; - } - - print "$msg\n"; - my $cmd = "set -o pipefail;" - . "$c2cmd $chicken @ARGV </dev/null 2>&1 | tee /tmp/$c2cmd.out"; - my @placelines = `$cmd`; - my $status = $?; + print "$desc, running for svn.\n"; + my ($status,@placelines) = &run_c2l ("p"); print @placelines; if ($status) { - print "$prg: *** do_place($c2cmd) failed, exiting.\n"; - - } elsif ($c2cmd ne "c2b" && $place_branch) { - $status = &do_place ("running c2b for svn branch", "c2b"); + print "$prg: *** do_place failed, exiting.\n"; } return $status; } + + +# Run c2l, specifying ARG. Return a list with the exit status +# and then all output lines. +# +sub run_c2l { + my ($arg) = @_; + my $tmpfile = "/tmp/c2l$arg.out"; + my @ret = `set -o pipefail; c2l $arg @ARGV </dev/null 2>&1 | tee $tmpfile`; + return ($?, @ret); +} diff --git a/Master/tlpkg/doc/releng.txt b/Master/tlpkg/doc/releng.txt index f9ebde1a150..d49e11a9dad 100644 --- a/Master/tlpkg/doc/releng.txt +++ b/Master/tlpkg/doc/releng.txt @@ -369,7 +369,8 @@ tar -C /home/httpd/html -czf ~karl/tmp/catalogue-freeze.tgz catalogue Z1. When sure it's going to fly, ask for torrents to be created. In 2022, Tim Stewart <timoteostewart1977@gmail.com> - made the one that worked. + made the one that worked. Ask him when final pretest appears stable, + don't wait for release (ideally). Part III. Making the big release. @@ -387,6 +388,7 @@ mkdir $hx/$this chgrp texlive !$ chmod g+ws !$ ls -ld !$ +ls !$ # should be empty cd /home/ftp/texlive/Images cp -pv README.md $hx/$prev/ @@ -403,11 +405,21 @@ mkdir $hm/$prev/ cd ~ftp/tex/mactex chgrp mactex *; chmod g+w * mv -v *.pkg* $hm/$prev -# should be only MacTeXtras.zip* and related left. +ls # should be only MacTeXtras.zip* and related left. mv -v ~ftp/texlive/tlpretest/*.pkg* . +# +# make generic symlinks: +ln -s mactex-basictex-20230314.pkg BasicTeX.pkg +ln -s mactex-ghostscript-10.0.0-20230218.pkg Ghostscript.pkg +ln -s mactex-20230314.pkg MacTeX.pkg +# +# and checksums for them: +for f in *.pkg; do echo $f; md5sum $f >$f.md5; sha512sum $f >$f.sha512; done +# edit README chgrp mactex *; chmod g+w * mkdir $hm/$this/ +ls !$ # should be empty cp -pv Extras*.pdf mactex-MacTeXtras*.zip $hm/$this - move rest of tlnet to historic, as tlnet-final: @@ -417,6 +429,7 @@ mkdir $hx/$prev/tlnet-final chgrp texlive !$ chmod g+s !$ ls -ld !$ +ls !$ # should be empty cd /home/ftp/texlive/tlnet mv [a-z]* $hx/$prev/tlnet-final rm -i TEXLIVE_20* # remove old signal file @@ -431,14 +444,15 @@ touch TEXLIVE_$this # empty file to signal new version - Source directory for CTAN: fx=/home/ftp/tex ls $fx/texlive/Source/* # ensure last year's sources -rm -f !$ +rm -f !$ # yep, remove them, we have have them in historic cp -av $tm/source/{install-tl,texlive-,windows-src-}*z $fx/texlive/Source/ cp -av $tm/source/{install-tl,texlive,windows-src}*README $fx/texlive/Source/ - historic copy of TL web pages: cd /home/httpd/html/texlive mkdir $hx/$prev/web/ -cp *.html !$ # disable header.html include in bugs.html +cp *.html !$ +ls !$/bugs.html # disable header.html ssi in that bugs.html - copy full (unpruned) tlpdb to historic: # the pre-pruned tlpdb directory is created by tl-update-images. @@ -449,10 +463,11 @@ tgz=/tmp/texlive-${this}0321-tlpdb-full.tar.gz # release date, not today's mv $tgz $hx/$this/ rm -rf $preprune -- update local CTAN area, just to avoid mirroring everything back again. +- email ctan@ctan.org. + update local CTAN area, just to avoid mirroring everything back again. Need to do this after the night's mirror-ctan is done, since CTAN won't have updated yet, most likely. -cd /home/ftp/texlive/tlnet # still +cd /home/ftp/texlive/tlnet cy=/home/ftp/tex-archive/systems rm -rf $cy/texlive/tlnet/*; cp -ar * $cy/texlive/tlnet/ rm $cy/texlive/Images/*; cp -a ../Images/*.* $cy/texlive/Images/ @@ -466,7 +481,7 @@ mount /mnt/tl cd /mnt/tl TEXLIVE_INSTALL_NO_RESUME=1; export TEXLIVE_INSTALL_NO_RESUME echo i | time nice -19 perl install-tl # do full install to default location - # takes about 30min + # takes about 40min rm /usr/local/texlive-rel && ln -s texlive/$this /usr/local/texlive-rel ls !$ newsrc=!$/source @@ -477,7 +492,9 @@ ls -l !$ mount /home/ftp/texlive/Contents/live cd umount /mnt/tl -chmod -R a-w /usr/local/texlive-rel/ # make unwritable, we should never change +# make files unwritable, we should never change; +# but keep directories writable, else backup-external fails. +find "$@" -xtype f -print0 | xargs -0 chmod a-w,a+r /usr/local/texlive-rel/ - update ~www/texlive web pages (search for $prev and $prev-1): acquire* - general @@ -490,6 +507,7 @@ chmod -R a-w /usr/local/texlive-rel/ # make unwritable, we should never change upgrade.html - whether possible or not tlmgr-news.html - from texmf-dist/scripts/texlive/NEWS index.html - dates + and site home page: ~www/index.html check for new Texinfo manuals to link to html versions, and if any, make a new link in: ~www/texinfohtml/ @@ -499,10 +517,11 @@ Before: Determine revision number from https://tug.org/pipermail/tex-live-commits/ Also, look at https://tug.org/svn/texlive/tags/ to get subnum and https://tug.org/svn/texlive/branches/ to avoid duplication. -rev=62882 -subnum=0 # increase as necessary if multiple branches needed +rev=66589 +subnum=0 # increment as necessary if multiple branches needed tlyear=`date +%Y`; echo $tlyear # maybe previous year during pretest, as above -svn copy -r $rev \ +# rerun without echo after checking +echo svn copy -r $rev \ -m"texlive-$tlyear.$subnum tag based on r$rev" \ svn://tug.org/texlive/trunk \ svn://tug.org/texlive/tags/texlive-$tlyear.$subnum @@ -550,15 +569,18 @@ re-adding would not do. (But renamed files are not handled, it seems.) - increment source versions, increment year+libversions and append /dev: Build/source/{version.ac,texk/{kpathsea,ptexenc}/version.ac reautoconf -svn commit -m'tlYY/dev' Build/source - -- update ~karl/bin/cron.tl, be sure cron.pretest and cron.branch are disabled, -and reenable cron.trunk when feel ready: -critical= -images_frozen=true +cd Build/source +svn status +svn commit -m"tl$YY/dev" . + +- confirm cron.pretest and cron.branch are disabled. +- update ~karl/bin/cron.tl and reenable cron.trunk when feel ready: +critical= # for trunk +images_frozen=true # for all net_frozen=false all_frozen=false catalogue_compare=true intermittently +tl_update_auto=true # Also disable cron.synctl /home/texlive/branch and enable plain cron.synctl. # |