When we prepare a document using LaTeX, sometimes we want to include line numbers in an article. In many peer reviewed journals, it is a requirement to include line numbers in the output.
For instance,
Elsevier LaTeX instructions has a
LaTeX template whose LaTeX template file starts with
\documentclass[review]{elsarticle}
\usepackage{lineno,hyperref}
You system has not had the lineno package installed, if you encounter the following error when you compile your LaTex file that uses package
lineno
,
! LaTeX Error: File `lineno.sty' not found.
Type X to quit or to proceed,
or enter new name. (Default extension: sty)
Enter file name:
Although you can download and install it from
CTAN, you may be better off by installing the appropriate package provided by your system and let your system manage it.
For instance, on Ubuntu Linux, we can install the
textlive-humanities
package,
sudo apt-get install texlive-humanities
For instance, on Fedora Linux, we can install the
texlive-collection-humanities
package,
sudo yum install texlive-collection-humanities
The solution comes from the posts at
here and
here.