Well I am afraid that it is duplicate question but I have searched over 8 posts and haven't succeeded. I tried to install in Ubuntu 18.04 TexLive 2021/TL2021 (I am using texstudio). I had previously unsuccessfully downloaded TL2021 but continued using TL2017. I did exactly the following steps:
In terminal
sudo apt autoremove --purge texlive tex-common
rm -rf /usr/local/texlive/2021
rm -rf ~/.texlive2021
rm -rf ~/.texlive2017
Deleted manually from the file's manager any files relative to TL2017 (I don't remember the exact names, but they were like texlive2017
)
Downloaded the tar.gz file from the TUG site and (tried) to follow the instuctions.
Changed directory (from terminal) where the unzipped install-tl perl file was.
Executed perl install-tl
(didn't work), so I executed sudo perl install-tl
(maybe it was an unsafe choice)
Entered code and -i option.
(After 2 hours approximately that the packages were downloaded and because I thought they were commands)
PATH=/usr/local/texlive/2021/bin/x86_64-linux
MANPATH=/usr/local/texlive/2021/texmf-dist/doc/man
INFOPATH=/usr/local/texlive/2021/texmf-dist/doc/info
(didn't give output)
Found the .profile
file and while it was
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH= PATH="$HOME/bin:$PATH"
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/.local/bin" ] ; then
PATH="$HOME/.local/bin:$PATH"
fi
I changed it to
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="/usr/local/texlive/2021/bin/x86_64-linux:$PATH; export PATH"
INFOPATH="$INFOPATH=/usr/local/texlive/2021/texmf-dist/doc/info; export INFOPATH"
MANPATH="$MANPATH=/usr/local/texlive/2021/texmf-dist/doc/man; export MANPATH"
fi
#OLD ONE
# PATH="$HOME/bin:$PATH"
#PATH=/usr/local/texlive/2021/bin/x86_64-linux:$PATH; export PATH
#INFOPATH=$INFOPATH=/usr/local/texlive/2021/texmf-dist/doc/info; export INFOPATH
#MANPATH=$MANPATH=/usr/local/texlive/2021/texmf-dist/doc/man; export MANPATH
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/.local/bin" ] ; then
PATH="/usr/local/texlive/2021/bin/x86_64-linux:$PATH"
INFOPATH="$INFOPATH=/usr/local/texlive/2021/texmf-dist/doc/info; export INFOPATH"
MANPATH="$MANPATH=/usr/local/texlive/2021/texmf-dist/doc/man; export MANPATH"
fi
#OLD ONE
# PATH="$HOME/.local/bin:$PATH"
Maybe it is wrong. I don't know.
From searching on this posts
1,2,3,4,5,6,7,8,9,10, I tried the following
which tex
export PATH=/usr/local/texlive/2021/bin/x86_64-linux:$PATH
export INFOPATH=$INFOPATH=/usr/local/texlive/2021/texmf-dist/doc/info
export MANPATH=$MANPATH=/usr/local/texlive/2021/texmf-dist/doc/man
echo $PATH
whereis pdftex
None of them gave a result. So I am a little bit confused. What did I do wrong or what didn't I do? Texstudio can't compile any tex file now.