I loaded lineno to number the lines on my resume for critique by a professor. Doing so changed the spacing after the headers. I would like to number the lines and retain the original formatting, if possible.

\documentclass{article}
\usepackage{fullpage}
\pagestyle{empty}
\raggedright

% Uncommenting lineno changes spacing below \header
%\usepackage{lineno}

\newcommand{\area}[2]{\vspace*{-9pt} \begin{verse}\textbf{#1}   #2 \end{verse}  }
\newcommand{\lineunder}{\vspace*{-8pt} \\ \hspace*{-18pt} \hrulefill \\}

\newcommand{\schoolwithcourses}[4]{
\textbf{#1} #2 $\bullet$ #3 $\bullet$ #4\\
Selected Coursework:\\
\vspace*{5pt}
}

\begin{document}

\schoolwithcourses{Bachelor of Science}{$\bullet$ Georgia Gwinnett College}{May 2013 $\bullet$ Magna cum Laude}
{GPA: 3.874/4.000}
\area{Biology}{Microbiology $\cdot$ Immunology $\cdot$ Human Anatomy $\cdot$ Human Physiology $\cdot$ Biomechanics $\cdot$ Organic~Chemistry $\cdot$ Biotechnology $\cdot$ Biochemistry $\cdot$ Cell Biology }
\end{document}

• The solution is to load lineno before \raggedright. – karlkoeller Sep 7 '13 at 16:41
• How would I ever know that? – John Johnson Sep 7 '13 at 17:06
• To respond to your question about how you would know that, in this case I think the following rule of thumb could be followed: load all packages before using any commands that are related to actually typesetting text such as \raggedright (which usually would go after \begin{document}.) This won't solve package loading order problems, but will prevent this sort of problem from arising. See also What's the right order when loading packages?. – Alan Munn Sep 8 '13 at 3:32

NEVER use any command related to typesetting text (\raggedright in your case) in the preamble.

lineno.sty redefines the meaning of \\ (which you're using in your \newcommands) and issuing \raggedright before that redefinition causes the conflict.

These are the lines in lineno.sty which cause the conflict:

\DeclareRobustCommand\\{%
\ifLineNumbers
\expandafter \@LN@cr
\else
\expandafter \@normalcr
\fi
}


LineNumbers is false in your case, so \\ gets defined as \@normalcr, which is the "fragile" version of \\.