diff options
author | Karl Berry <karl@freefriends.org> | 2022-08-28 21:08:59 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2022-08-28 21:08:59 +0000 |
commit | d7c17c9014987de25a4bf2df6bcc0f6427f7b7fd (patch) | |
tree | 8da5a8689b64b94188006f7a6bc5f28d86f8b207 /Master/tlpkg/bin | |
parent | 15f60291051d3cd3e454d2011fbb0d135c6ed47d (diff) |
c2a: new script to automatically run place if no changes.
tlpkg-ctan-check: do not check magicwatermark (author never updates) or
m-tx (binaries).
releng.tex: make texlive-rel unwritable.
place: sort directory lists.
others: doc tweaks, sync.
git-svn-id: svn://tug.org/texlive/trunk@64220 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/bin')
-rwxr-xr-x | Master/tlpkg/bin/c2a | 101 | ||||
-rwxr-xr-x | Master/tlpkg/bin/tl-check-fmtshare | 2 | ||||
-rwxr-xr-x | Master/tlpkg/bin/tl-update-tlnet | 2 | ||||
-rwxr-xr-x | Master/tlpkg/bin/tlpkg-ctan-check | 2 |
4 files changed, 105 insertions, 2 deletions
diff --git a/Master/tlpkg/bin/c2a b/Master/tlpkg/bin/c2a new file mode 100755 index 00000000000..5ab303bcfbc --- /dev/null +++ b/Master/tlpkg/bin/c2a @@ -0,0 +1,101 @@ +#!/usr/bin/env perl +# $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.) + +use strict; use warnings; + +(my $prg = $0) =~ s,.*/,,; + +my $place_branch = 0; +#my $chicken = ""; +my $chicken = "-p"; + +exit (&main ()); + +sub main { + my $place = 0; + if ($ARGV[$#ARGV] =~ /^-?p$/) { + pop (@ARGV); + $place = 1; + } + printf "$prg: running c2l..."; + my @lines = `set -o pipefail; c2l @ARGV </dev/null 2>&1 | tee /tmp/c2l.out`; + if ($?) { + print "first c2l failed, exiting.\n"; + print @lines; + exit $?; + } + + 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 @lines; + $status = 0; + last; + } else { + $status = &do_place ("no new or removed files"); + last; + } + + } elsif ($place) { + $status = &do_place ("new/removed files, but p(lace) given"); + last; + + } else { + print "have new/removed files, exiting.\n"; + print @lines; + last; + } + } + } + + 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; + } + } + + return $status; +} + + +sub do_place { + my ($desc,$c2cmd) = @_; + + 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 @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"); + } + + return $status; +} diff --git a/Master/tlpkg/bin/tl-check-fmtshare b/Master/tlpkg/bin/tl-check-fmtshare index a93883c680c..d9d339fba47 100755 --- a/Master/tlpkg/bin/tl-check-fmtshare +++ b/Master/tlpkg/bin/tl-check-fmtshare @@ -255,7 +255,7 @@ for fmt in $fmts; do exit 1 fi #echo "$0: (`date`)" - echo "$0: built fmtfile: `ls -l $fmtfile`" + echo "$0: built fmtfile: `ls -l $fmtfile`" (on `hostname`) engineversion=`$enginedir/$engine --version | sed 1q` echo "$0: with engine: $enginedir/$engine ($engineversion)" diff --git a/Master/tlpkg/bin/tl-update-tlnet b/Master/tlpkg/bin/tl-update-tlnet index 440207a3865..6c08c7c95d1 100755 --- a/Master/tlpkg/bin/tl-update-tlnet +++ b/Master/tlpkg/bin/tl-update-tlnet @@ -305,7 +305,7 @@ install_tl_log=$tltryinst/$yyyy/install-tl.log if test -r $install_tl_log \ && grep -i '^fmtutil.*error.*' $install_tl_log >/dev/null; then echo >&2 - echo "$prg: seems fmtutil failed, check $install_tl_log." >&2 + echo "$prg: seems fmtutil failed, check: $install_tl_log" >&2 failure=true else : # appease -e diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check index 2af2a009d2e..817e6b8bb74 100755 --- a/Master/tlpkg/bin/tlpkg-ctan-check +++ b/Master/tlpkg/bin/tlpkg-ctan-check @@ -960,6 +960,8 @@ my @TLP_no_check = ( "luatex", # binary "luahbtex", # binary "luajittex", # binary + "m-tx", # binary + "magicwatermark", # 28aug22 awaiting upload with .dtx fix "makeindex", # binary "malayalam-latex", # binary "metafont", # binary |