diff --git a/README.md b/README.md index 7b4f43e..769f08f 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ Here is the [handin-doc.pdf](https://raw.githubusercontent.com/Strauman/Handin-L ## Versions The current latest version available on GitHub is v0.0.3 (2018/04/04) build 41 -The current latest version available on CTAN is 0.0.2 (2018-04-01) build 2 +The current latest version available on CTAN is v0.0.3 (2018/04/04) build 41 *Be aware that it can take at least 24-48 hours from the CTAN date above until the package is updated on CTAN, TeXLive and MiKTeX are updated* diff --git a/docs/changelog.tex b/docs/changelog.tex index bb0b53c..87805b5 100644 --- a/docs/changelog.tex +++ b/docs/changelog.tex @@ -4,6 +4,6 @@ v0.0.2&2018/04/01&Problems are now added to the table of contents by default\\ v0.0.2b34&2018/04/02&Updated documentation syntax\\ v0.0.3b41&2018/04/04&\begin{itemize} - \item German language added + \item German language added by africola \newline (\url{https://github.com/africola}) \end{itemize}\\ \end{tabularx} diff --git a/docs/handin-doc.pdf b/docs/handin-doc.pdf index 96989cc..6945e5a 100644 Binary files a/docs/handin-doc.pdf and b/docs/handin-doc.pdf differ diff --git a/docs/handin-doc.tex b/docs/handin-doc.tex index f7c270f..557a5d2 100644 --- a/docs/handin-doc.tex +++ b/docs/handin-doc.tex @@ -44,6 +44,9 @@ \makeatother \let\dac\docAuxCommand \tcbset{documentation listing style=mydocumentation} +% Magenta HREF style +\let\oldhref\href +\gdef\href#1#2{{\color{magenta}\oldhref{#1}{#2}}} % Give section some space \let\oldsection\section \gdef\section{\needspace{0.3\paperheight}\oldsection} @@ -95,6 +98,20 @@ \subsection{Page formatting commands} This is the text that is on the bottom right corner reading "Page x of y". Default is \dac{pagetext}\{Page \dac{thepage}~of \dac{pageref}{LastPage\}} \end{docCommand} +\subsection{Languages} +This package supports. +\begin{itemize} +\item English +\item Norwegian +\item German (by \href{https://github.com/africola}{africola}) + + +\end{itemize} +Translations are welcome at \url{https://github.com/Strauman/Handin-LaTeX-template/tree/master/src/languages}. +The current language is set by the \texttt{iflang} package, so you can use e.g. babel: +\begin{dispListing} +\usepackage[german]{babel} +\end{dispListing} \subsection{General reference} \begin{docCommand}{problem}{\marg{text}} This command will print out a problem header. For example \dac{problem}\{1\} @@ -138,7 +155,7 @@ \section{Changelog} v0.0.2&2018/04/01&Problems are now added to the table of contents by default\\ v0.0.2b34&2018/04/02&Updated documentation syntax\\ v0.0.3b41&2018/04/04&\begin{itemize} - \item German language added + \item German language added by africola \newline (\url{https://github.com/africola}) \end{itemize}\\ \end{tabularx} \end{document} diff --git a/handin-doc.pdf b/handin-doc.pdf index 96989cc..6945e5a 100644 Binary files a/handin-doc.pdf and b/handin-doc.pdf differ diff --git a/src/README.template.md b/src/README.template.md index 5b655f3..f71a762 100644 --- a/src/README.template.md +++ b/src/README.template.md @@ -4,7 +4,7 @@ Here is the [handin-doc.pdf](https://raw.githubusercontent.com/Strauman/Handin-L ## Versions The current latest version available on GitHub is @@VERSION (@@DATE) build @@BUILD -The current latest version available on CTAN is 0.0.2 (2018-04-01) build 2 +The current latest version available on CTAN is v0.0.3 (2018/04/04) build 41 *Be aware that it can take at least 24-48 hours from the CTAN date above until the package is updated on CTAN, TeXLive and MiKTeX are updated* diff --git a/src/aftercompile.sh b/src/aftercompile.sh index c314f96..e441110 100755 --- a/src/aftercompile.sh +++ b/src/aftercompile.sh @@ -29,15 +29,17 @@ rm $CTANDir/layout.tex mv ../README.md ../README.md.bak echo -e "" > ../README.md cat README.template.md >> ../README.md +pushd . >/dev/null cd ../ outHandle "Error when inserting package-variables to README.md-file" $perlDir/vars.pl -v $version -p $packagename -g $github -b $build README.md +popd >/dev/null # Zip CTAN file sleep 0.3 echo "Zipping CTAN" rm haninCTAN.zip zip handinCTAN.zip -r "$packagename/" - +sleep 0.3 rm -rf "$mainDir/handin" mv "$sourceDir/handinCTAN.zip" "$mainDir/" mv "$CTANDir/" "$mainDir/$packagename" diff --git a/src/languages/deDE.tex b/src/languages/deDE.tex index b89ee6a..5721962 100644 --- a/src/languages/deDE.tex +++ b/src/languages/deDE.tex @@ -1,4 +1,6 @@ %!TEX root = ../main.tex +%:$LANGUAGES.=\!item German (by \!href{https://github.com/africola}{africola}) +%:- \set@tr{Problem}{Aufgabe} \set@tr{problem}{Aufgabe} \set@tr{containspages}{Enthält \pageref{LastPage} Seiten, inklusive Titelseite} diff --git a/src/languages/enUS.tex b/src/languages/enUS.tex index 6eb925c..e68ec43 100644 --- a/src/languages/enUS.tex +++ b/src/languages/enUS.tex @@ -1,4 +1,6 @@ %!TEX root = ../main.tex +%:$LANGUAGES.=\!item English +%:- \set@tr{Problem}{Problem} \set@tr{problem}{problem} \set@tr{containspages}{Contains \pageref{LastPage} pages, front page included} diff --git a/src/languages/languagedelegator.tex b/src/languages/languagedelegator.tex index 203f3d5..a4afa99 100644 --- a/src/languages/languagedelegator.tex +++ b/src/languages/languagedelegator.tex @@ -1,8 +1,12 @@ %!TEX root = ../main.tex -%\BDOC -%§lang -%This package supports norwegian, german and english. Translations are welcome at \url{https://github.com/Strauman/Handin-LaTeX-template/tree/master/src/languages}. that are set by the \!\texttt{iflang} package. -% +%:§lang +%:This package supports. +%:\!begin{itemize} +%:$$LANGUAGES +%:\!end{itemize} +%:Translations are welcome at \!url{https://github.com/Strauman/Handin-LaTeX-template/tree/master/src/languages}. +%:The current language is set by the \!texttt{iflang} package, so you can use e.g. babel: +%:!\usepackage[german]{babel} %:- \makeatletter \def\@tr#1{ diff --git a/src/languages/nbNO.tex b/src/languages/nbNO.tex index 6046c68..c87b70a 100644 --- a/src/languages/nbNO.tex +++ b/src/languages/nbNO.tex @@ -1,4 +1,6 @@ %!TEX root = ../main.tex +%:$LANGUAGES.=\!item Norwegian +%:- \makeatletter \set@tr{Problem}{Oppgave} \set@tr{problem}{oppgave}