"tlmgr" on "Ubuntu 22.04"

Max Chernoff mseven at telus.net
Fri Jul 29 02:11:28 CEST 2022


>  4. peacecop at peacecop-HP-ProBook-4520s:~$ mkdir -p ~/.config/environment.d/
>     peacecop at peacecop-HP-ProBook-4520s:~$ echo
>     'PATH=/usr/local/texlive/2022/bin/x86_64-linux/:${PATH}' >
>     ~/.config/environment.d/texlive-path.conf
>     After reboot, /TeXstudio/ works like before and no /sudo/ is needed.
>     Even /tex-locale/ is found. However, /tlmgr/ still acts weird:
>     peacecop at peacecop-HP-ProBook-4520s:~$ tlmgr install tex-locale
>     You don't have permission to change the installation in any way,
>     specifically, the directory /usr/local/texlive/2022/tlpkg/ is not
>     writable.
>     Please run this program as administrator, or contact your local admin.
>     tlmgr: An error has occurred. See above messages. Exiting.
>     peacecop at peacecop-HP-ProBook-4520s:~$ sudo tlmgr install tex-locale
>     [sudo] password for peacecop:
>     sudo: tlmgr: command not found
>     peacecop at peacecop-HP-ProBook-4520s:~$ which tlmgr
>     /usr/local/texlive/2022/bin/x86_64-linux/tlmgr
>     If i do just /tlmgr list/ then i get the list.

Alright, so it looks like the path is set correctly for your user now.
Sudo resets most of the environment when it's ran, so it can't find
tlmgr. 

Probably the easiest way to fix this is to run

   sudo visudo
   
then add your TL bin path to the path list, which is on the line beginning
with:

   Defaults    secure_path
   
-- Max
   



More information about the tex-live mailing list.