これらのキーワードがハイライトされています:tlmgr

tlmgr

tlmgrTeX Live のパッケージ管理ツールで,コマンドラインで使用します. GUI 版としては TeX Live Shell (GUI 版 TeX Live Manager) や macOS の TeX Live Utility もあります.

使い方

公式ドキュメントに解説があります.

$ tlmgr --help

でもマニュアルが表示されます.

TeX Live のアップデート

コマンドラインから以下のコマンドを実行します.

インストールされているパッケージの情報を見る(ライセンス・バージョン確認など)

たとえば geometry パッケージについて調べる場合は,以下のコマンドを実行します.

$ tlmgr info geometry
package:     geometry
category:    Package
shortdesc:   Flexible and complete interface to document dimensions
longdesc:    The package provides an easy and flexible user interface to customize page layout, implementing auto-centering and auto-balancing mechanisms so that the users have only to give the least description for the page layout. For example, if you 
want to set each margin 2cm without header space, what you need is just \usepackage[margin=2cm,nohead]{geometry}. The package knows about all the standard paper sizes, so that the user need not know what the nominal 'real' dimensions of the paper are, 
just its standard name (such as a4, letter, etc.). An important feature is the package's ability to communicate the paper size it's set up to the output (whether via DVI \specials or via direct interaction with pdf(La)TeX).
installed:   Yes
revision:    61719
sizes:       src: 325k, doc: 921k, run: 45k
relocatable: No
cat-version: 5.9
cat-license: lppl1.3c
cat-topics:  geometry
cat-related: vmargin typearea geometry-de
cat-contact-bugs: https://github.com/LaTeX-Package-Repositories/geometry/issues
cat-contact-repository: https://github.com/LaTeX-Package-Repositories/geometry
collection:  collection-latex

過去のパッケージを復元する

ときどき,tlmgr で更新したパッケージに不具合が混入したり,他のパッケージとの共存で不都合が生じたりすることもあります. 問題のなかった古いバージョンを復元したくなることがあると思います.

たとえば,tlmgr でパッケージを一斉にアップデートしたところ,luatexja の r39527 で不都合が生じたとして,以前にインストールされていたバージョンに復旧したいとします. その場合,以下のコマンドを実行します.

$ tlmgr restore luatexja

バックアップが残っている場合は,ローカルに保存されているリビジョン番号が表示されます.

Available backups for luatexja: 39105 (2016-02-02 15:45)

確認したら,そのリビジョン番号を復元します.

$ sudo tlmgr restore luatexja 39105

一度確認されます.

Do you really want to restore luatexja to revision 39105 (y/N):

y で進むと

Restoring luatexja, 39105 from /usr/local/texlive/2015/tlpkg/backups/luatexja.r39105.tar.xz

などと表示され,過去のパッケージが展開されます.

なお,フォーマット作成時に読まれるファイルを復元した場合(たとえば LaTeX 本体に不具合が生じ,過去のバージョンを復元した場合)は,手動でフォーマットを再作成する必要が生じます.

関連リンク


Last-modified: 2025-03-10 (月) 22:52:55 (432d)