If you are willing to use a shell-escape (i.e. compile with 'latex --shell-escape'), you can probably use 'uname' on Unix-like platforms and on Cygwin...
\documentclass{article}
\makeatletter
% redefine \author as \maketitle clears \@author...
\let\oldAuthor=\author
\renewcommand{\author}[1]{\oldAuthor{#1}\gdef\ShowAuthor{#1}}
\newcommand{\ShowOsVersion}{%
\immediate\write18{\unexpanded{foo=`uname -a` && echo "\\verb+${foo}+" > tmp.tex}}%
\input{tmp}\immediate\write18{rm tmp.tex}%
}
\makeatother
\title{This is a Document}
\author{John Smith}
\begin{document}
\maketitle
Compiled on: \today
Compiled by: \ShowAuthor
OS version: \ShowOsVersion
\LaTeX{} version: \LaTeXe~\fmtversion
\end{document}
If you want something similar on Windows, I think you could use something along the lines of...
\immediate\write18{systeminfo | findstr /B /C:"OS Name" /C:"OS Version" > tmp.tex}
and maybe restructure slightly - for instance, you'll need to remove the "OS Version:" from the main text because this 'systeminfo' command outputs more than just the version number - for me it outputs
OS Name: Microsoft Windows 7 Professional
OS Version: 6.1.7601 Service Pack 1 Build 7601
{}
).ifplatform
package to set different phrases depending on the operating system. The version of LaTeX is just a date that you can get with\fmtversion
, for instance\LaTeX{} version: \LaTeXe~\fmtversion