I am doing a PHP script to write a .tex file.
Based in this insert a horizontal cut line, I want to "print" many block on one page, and between block I want draw a "cut line".
But I dont want draw a cut line at bottom of page.
The script write:
- BLOCK
- LINE
- BLOCK
- LINE
- BLOCK
- ...
For this example I am using minipage to avoid break the "block" and inserting the cut line between this "blocks"
EDITED now with an cycle method
\documentclass[12pt]{article}
\usepackage[T1]{fontenc}
\usepackage{pifont}
\usepackage{fancyhdr}
\fancyhf{}
\renewcommand{\headrulewidth}{0pt}
\usepackage{lipsum}
\usepackage[letterpaper, portrait, tmargin=8mm, bmargin=10mm]{geometry}
\usepackage{pgffor}
\begin{document}
This line its for fix width \\
% JUST REPEAT BLOCK MANY TIMES (NOT REAL BUT WORKS FOR EXAMPLE)
\foreach \n in {1,...,3}{
% START BLOCK
\begin{minipage}{\textwidth}
\textbf{{\large Block Number \n}} \\
\lipsum[2-4]
\end{minipage}
\vspace{\baselineskip}
\noindent\dotfill\ding{33}\dotfill
\vspace{\baselineskip}
% END BLOCK
}
\end{document}
As you can see in the image, the cut line it pointless at the end of the page, it does not should to be drawn/inserted
I think it can be solved using something like needspace, but I would not know how to start.

