From 064f54f6e13dde7522bfb4d727745a3ddefbafb8 Mon Sep 17 00:00:00 2001 From: John Swinbank <swinbank@astron.nl> Date: Fri, 25 Jun 2021 17:53:07 +0200 Subject: [PATCH] Add example structure --- .gitignore | 16 +++++++++++++++ .gitlab-ci.yml | 13 ++++++++++++ Makefile | 12 +++++++++++ main.tex | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 95 insertions(+) create mode 100644 .gitignore create mode 100644 .gitlab-ci.yml create mode 100644 Makefile create mode 100644 main.tex diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..efc98fa --- /dev/null +++ b/.gitignore @@ -0,0 +1,16 @@ +*.aux +*.bbl +*.bcf +*.blg +*.glg +*.glo +*.gls +*.ist +*.log +*.out +*.pdf +*.toc +*.run.xml +changes.tex +meta.tex +texput.log diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..014983e --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,13 @@ +image: registry.gitlab.com/islandoftex/images/texlive:latest + +variables: + GIT_SUBMODULE_STRATEGY: normal + +build: + before_script: + - apt-get update && apt-get install -y git-lfs + script: + - make + artifacts: + paths: + - *.pdf diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..6f26aee --- /dev/null +++ b/Makefile @@ -0,0 +1,12 @@ +DOCHANDLE=SDC-example +export TEXMFHOME ?= astron-texmf/texmf + +$(DOCHANDLE).pdf: main.tex meta.tex changes.tex + xelatex -jobname=$(DOCHANDLE) main.tex + makeglossaries $(DOCHANDLE) + biber $(DOCHANDLE) + xelatex -jobname=$(DOCHANDLE) main.tex + xelatex -jobname=$(DOCHANDLE) main.tex + +include astron-texmf/make/vcs-meta.make +include astron-texmf/make/changes.make diff --git a/main.tex b/main.tex new file mode 100644 index 0000000..b3a08a8 --- /dev/null +++ b/main.tex @@ -0,0 +1,54 @@ +% documentclass{} takes the following mutually-exclusive options: +% +% note -- formats the document as a technical note. +% proposed -- formats the document as a proposed change to the baseline. +% baseline -- formats the document as part of the technical baseline. +\documentclass[note]{astron} + +\input{meta} +\input{changes} + +\setDocTitle{ASTRON SDC Document Example} +\setDocProgram{SDC} +\setDocAuthors{ + \addPerson{John D. Swinbank}{ASTRON}{\vcsDate} +} + +% These are set according to information obtained from make and git. +\setDocNumber{\docHandle} +\setDocRevision{\vcsRevision} +\setDocDate{\vcsDate} + + +\begin{document} +\maketitle + +\printglossary[title=List of Abbreviations] +\clearpage + +\section{Getting Started} +\label{sec:getting-started} + +\begin{enumerate} + + \item{Edit \verb|Makefile| and set \verb|DOCHANDLE| to the appropriate handle for your document. + Refer to the \href{https://support.astron.nl/confluence/display/SDCP/List+of+SDC-Series+Documents}{list of SDC series documents} which have been issued to date, and choose the next one in sequence.} + + \item{Check the preamble of this file to ensure that the document title, programme, and author(s) have been set correctly.} + + \item{Insert your text here.} + + \item{Use the \verb|\gls| command to refer to abbreviations, like \gls{SDC}.} + + \item{Use the \verb|\autocite| command to cite other documents, like \autocite{SDC-006}.} + + \item{Use the \verb|\cref| command to refer to sections, tables, or other material in this document, like \cref{sec:getting-started}.} + + \item{Run \verb|make| to compile the document.} + +\end{enumerate} + +\clearpage +\printbibliography + +\end{document} -- GitLab