\ifx\gotpreamble\undefined

\documentstyle[part]{article}

\global\let\gotpreamble=t

\begin{document}
\fi
