| 1 |
# UnBTeX: A class for bachelor, master, and doctoral thesis at the |
| 2 |
# University of Brasilia (UnB), Brazil. |
| 3 |
# Version 1.6.4 2026/05/25 |
| 4 |
|
| 5 |
$pdf_mode = 1; |
| 6 |
$pdflatex = 'pdflatex -interaction=nonstopmode -halt-on-error %O %S'; |
| 7 |
|
| 8 |
# Número máximo de execuções do pdflatex conforme o ambiente. |
| 9 |
if (defined $ENV{'OVERLEAF_PROJECT_ID'}) { |
| 10 |
$max_repeat = 2; # Ambiente Overleaf (compilação parcial) |
| 11 |
# Faça max_repeat = 1 caso persista timeout |
| 12 |
# Faça max_repeat = 4 caso tenha a versão paga do Overleaf |
| 13 |
} else { |
| 14 |
$max_repeat = 4; # Ambiente local (compilação completa) |
| 15 |
} |
| 16 |
|
| 17 |
# Ativa bibtex automaticamente quando necessário |
| 18 |
$bibtex_use = 1; |
| 19 |
$bibtex = 'bibtex %O %S'; |
| 20 |
|
| 21 |
# Gera nomenclatura: de .nlo para .nls |
| 22 |
add_cus_dep('nlo', 'nls', 0, 'makenomencl'); |
| 23 |
sub makenomencl { |
| 24 |
# Só gera se o arquivo .nlo existir |
| 25 |
if (-e "$_[0].nlo") { |
| 26 |
system("makeindex -s nomencl.ist -o \"$_[0].nls\" \"$_[0].nlo\""); |
| 27 |
} |
| 28 |
} |