[tex-live] [PATCH] exit with error if restoring a package fails

Scott Kostyshak skostysh at lyx.org
Mon Mar 3 07:45:41 CET 2014


Otherwise a script might assume that the restore went successfully.

$ sudo /opt/texbin/tlmgr restore pst-mirror 16371
revision 16371 for pst-mirror is not present in
/usr/local/texlive/2013/tlpkg/backups
$ echo $?
0

The attached patch calls finish(1):
$ sudo /opt/texbin/tlmgr restore pst-mirror 16371
revision 16371 for pst-mirror is not present in
/usr/local/texlive/2013/tlpkg/backups
tlmgr: exiting unsuccessfully (status 1).
$ echo $?
1

Best,

Scott
-------------- next part --------------
1843c1843,1844
<     print "revision $rev for $pkg is not present in $opts{'backupdir'}\n";
---
>     tlwarn("revision $rev for $pkg is not present in $opts{'backupdir'}\n");
>     finish(1);


More information about the tex-live mailing list