summaryrefslogtreecommitdiff
path: root/Build
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2021-05-22 20:16:30 +0000
committerKarl Berry <karl@freefriends.org>2021-05-22 20:16:30 +0000
commit0d82bc72dfbcd013449447046870edb514c81784 (patch)
tree02884ad03c5b9126c748947c99638910389cd88d /Build
parent0b7bb0e5c26e2e478a73d0308ec2b5411a2b1ad2 (diff)
ltximg (22may21)
git-svn-id: svn://tug.org/texlive/trunk@59309 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build')
-rwxr-xr-xBuild/source/texk/texlive/linked_scripts/ltximg/ltximg.pl25
-rwxr-xr-xBuild/source/texk/texlive/linked_scripts/texlive/tlmgr.pl18
2 files changed, 22 insertions, 21 deletions
diff --git a/Build/source/texk/texlive/linked_scripts/ltximg/ltximg.pl b/Build/source/texk/texlive/linked_scripts/ltximg/ltximg.pl
index 791c9316856..2582d2d61da 100755
--- a/Build/source/texk/texlive/linked_scripts/ltximg/ltximg.pl
+++ b/Build/source/texk/texlive/linked_scripts/ltximg/ltximg.pl
@@ -31,7 +31,7 @@ use Config;
use Cwd;
use if $^O eq 'MSWin32', 'Win32';
use if $^O eq 'MSWin32', 'Module::Load::Conditional' => qw(can_load check_install requires);
-# Need on Windows cmd for colors, TeX Live not provide 'Win32::Console::ANSI'
+# Need for colors in Windows cmd, TeX Live not provide 'Win32::Console::ANSI'
if($^O eq 'MSWin32' && check_install( module => 'Win32::Console::ANSI')) {
require Win32::Console::ANSI;
}
@@ -44,8 +44,8 @@ my $workdir = cwd;
### Script identification
my $scriptname = 'ltximg';
my $program = 'LTXimg';
-my $nv = 'v2.0';
-my $date = '2021-01-24';
+my $nv = 'v2.1';
+my $date = '2021-05-21';
my $copyright = <<"END_COPYRIGHT" ;
[$date] - LaTeX environments to image and standalone files
END_COPYRIGHT
@@ -601,7 +601,7 @@ sub SearchRegistry {
return $found;
} # end GS search registry
-### This part is only necessary if you're using Git on windows and don't
+### This part is only necessary if you're using Git-bash on windows and don't
### have gs configured in PATH. Git for windows don't have a Win32::TieRegistry
### module for perl (is not supported in the current versions of msys).
sub Searchbyregquery {
@@ -2544,17 +2544,13 @@ if (@pst_exa and $outfile) {
$PALABRAS = qr/\b (?: pst-\w+ | pstricks (?: -add | -pdf )? | psfrag |psgo |vaucanson-g| auto-pst-pdf(?: -lua )? )/x;
$FAMILIA = qr/\{ \s* $PALABRAS (?: \s* [,] \s* $PALABRAS )* \s* \}(\%*)?/x;
-### Clean PST content in preamble
+### Clean PSTricks content in preamble
if ($clean{pst} and $outfile) {
Log("Remove pstricks packages in preamble for $opts_cmd{string}{output}$outext");
$preamble =~ s/\%<\*$dtxverb> .+?\%<\/$dtxverb>(*SKIP)(*F)|
^ $USEPACK (?: $CORCHETES )? $FAMILIA \s*//msxg;
$preamble =~ s/\%<\*$dtxverb> .+?\%<\/$dtxverb>(*SKIP)(*F)|
(?: ^ $USEPACK \{ | \G) [^}]*? \K (,?) \s* $PALABRAS (\s*) (,?) /$1 and $3 ? ',' : $1 ? $2 : ''/gemsx;
- if (@pst_exa) {
- Log("Uncomment pst-exa package in preamble for $opts_cmd{string}{output}$outext");
- $preamble =~ s/(?:\%)(\\usepackage\[\s*)(swpl|tcb)(,pdf\s*\]\{pst-exa\})/$1$2$3/msxg;
- }
Log("Remove \\psset\{...\} in preamble for $opts_cmd{string}{output}$outext");
$preamble =~ s/\%<\*$dtxverb> .+?\%<\/$dtxverb>(*SKIP)(*F)|
\\psset\{(?:\{.*?\}|[^\{])*\}(?:[\t ]*(?:\r?\n|\r))+//gmsx;
@@ -2566,6 +2562,12 @@ if ($clean{pst} and $outfile) {
^\\usepackage\{\}(?:[\t ]*(?:\r?\n|\r))+/\n/gmsx;
}
+### Uncomment pst-exa package
+if (@pst_exa and $outfile) {
+ Log("Uncomment pst-exa package in preamble for $opts_cmd{string}{output}$outext");
+ $preamble =~ s/(?:\%)(\\usepackage\[\s*)(swpl|tcb)(,pdf\s*\]\{pst-exa\})/$1$2$3/msxg;
+}
+
### To be sure that the package graphicx and \graphicspath is in the main
### document and not in a verbatim write environment we make the changes
my %tmpreplace = (
@@ -2807,9 +2809,10 @@ if ($outfile) {
}
# Remove internal mark for verbatim and verbatim write environments
$out_file =~ s/\%<\*$dtxverb>\s*(.+?)\s*\%<\/$dtxverb>/$1/gmsx;
- %replace = (%changes_out);
+ %replace = (%changes_out,%tmpoutreplace);
$find = join q{|}, map {quotemeta} sort { length $a <=> length $b } keys %replace;
$out_file =~ s/($find)/$replace{$1}/g;
+ # Write <output file>
if (-e "$opts_cmd{string}{output}$outext") {
Log("Rewriting the file $opts_cmd{string}{output}$outext in $workdir");
Infocolor('Warning', "The file [$opts_cmd{string}{output}$outext] already exists and will be rewritten");
@@ -2818,7 +2821,6 @@ if ($outfile) {
Infoline("Creating the file $opts_cmd{string}{output}$outext");
Log("Write the file $opts_cmd{string}{output}$outext in $workdir");
}
- # Write <output file>
open my $OUTfile, '>', "$opts_cmd{string}{output}$outext";
print {$OUTfile} $out_file;
close $OUTfile;
@@ -3281,4 +3283,3 @@ General Public License for more details.
gs(1), dvips(1), ps2pdf(1), pdfcrop(1), pdftops(1), pdftocairo(1), pdftoppm(1)
=cut
-
diff --git a/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl b/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
index bd9bb1175c1..07fac213c32 100755
--- a/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
+++ b/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
@@ -1,12 +1,12 @@
#!/usr/bin/env perl
-# $Id: tlmgr.pl 59287 2021-05-20 21:34:36Z karl $
+# $Id: tlmgr.pl 59291 2021-05-21 03:14:40Z preining $
#
# Copyright 2008-2021 Norbert Preining
# This file is licensed under the GNU General Public License version 2
# or any later version.
-my $svnrev = '$Revision: 59287 $';
-my $datrev = '$Date: 2021-05-20 23:34:36 +0200 (Thu, 20 May 2021) $';
+my $svnrev = '$Revision: 59291 $';
+my $datrev = '$Date: 2021-05-21 05:14:40 +0200 (Fri, 21 May 2021) $';
my $tlmgrrevision;
my $tlmgrversion;
my $prg;
@@ -398,6 +398,10 @@ sub main {
GetOptions(\%opts, keys(%optarg)) or pod2usage(2);
+ # load the config file and set the config options
+ # load it BEFORE starting downloads as we set persistent-downloads there!
+ load_config_file();
+
$::debug_translation = 0;
$::debug_translation = 1 if $opts{"debug-translation"};
@@ -422,7 +426,7 @@ sub main {
ddebug("action = $action\n");
for my $k (keys %opts) {
- ddebug("$k => $opts{$k}\n");
+ ddebug("$k => " . (defined($opts{$k}) ? $opts{$k} : "(undefined)") . "\n");
}
ddebug("arguments: @ARGV\n") if @ARGV;
@@ -669,10 +673,6 @@ for the full story.\n";
$loadmediasrcerror = "Cannot load TeX Live database from ";
- # load the config file and set the config options
- # load it BEFORE starting downloads as we set persistent-downloads there!
- load_config_file();
-
# in system mode verify that the selected action is allowed
if (!$opts{"usermode"} && $config{'allowed-actions'}) {
if (!TeXLive::TLUtils::member($action, @{$config{'allowed-actions'}})) {
@@ -10224,7 +10224,7 @@ This script and its documentation were written for the TeX Live
distribution (L<https://tug.org/texlive>) and both are licensed under the
GNU General Public License Version 2 or later.
-$Id: tlmgr.pl 59287 2021-05-20 21:34:36Z karl $
+$Id: tlmgr.pl 59291 2021-05-21 03:14:40Z preining $
=cut
# test HTML version: pod2html --cachedir=/tmp tlmgr.pl >/tmp/tlmgr.html