upload TinyTeX binaries

This commit is contained in:
Sina Atalay 2023-09-01 21:56:05 +02:00
parent c7a07f272d
commit 9ddbb5306f
15 changed files with 1115 additions and 790 deletions

1
.gitignore vendored
View File

@ -124,6 +124,7 @@ celerybeat.pid
.venv
env/
venv/
.venv/
ENV/
env.bak/
venv.bak/

View File

@ -21,3 +21,10 @@ with open(input_file_path) as file:
data = CurriculumVitae(**raw_json)
output_latex_file = template.render(data=data)
# Create an output file and write the rendered LaTeX code to it:
output_file_path = os.path.join(workspace, "tests", "outputs", "test.tex")
with open(output_file_path, "w") as file:
file.write(output_latex_file)

View File

View File

@ -0,0 +1 @@
C:\GIT\rendercv\rendercv\tinytex\vendor\TinyTeX\bin\windows\latexmk.exe -lualatex -c test.tex

View File

@ -0,0 +1,99 @@
\usepackage[ignoreheadfoot, top=\PageYMargin, bottom=\PageYMargin, left=\PageXMargin, right=\PageXMargin, headsep=0.3cm]{geometry}
\usepackage{fontspec}
\usepackage[explicit]{titlesec}
\usepackage{tabularx}
\usepackage{array}
\usepackage{xifthen}
\usepackage[dvipsnames]{xcolor}
\definecolor{primaryColor}{RGB}{\PRIMARYCOLOR}
\usepackage{enumitem}
\usepackage{fontawesome}
\usepackage[pdftitle={\AUTHOR's CV}, pdfauthor={\AUTHOR}, colorlinks=true, urlcolor=primaryColor]{hyperref} % Linking
% \setmainfont{SourceSansPro}[
% Path= fonts/,
% Extension = .ttf,
% UprightFont = *-Regular,
% ItalicFont = *-Italic,
% BoldFont = *-Bold,
% BoldItalicFont = *-BoldItalic]
% Calculate last update top margin:
\newlength\A
\newlength\B
\setlength\A{\PageYMargin}
\setlength\B{\dimexpr \numexpr \A / 1 \relax sp\relax}
\setcounter{secnumdepth}{0} % No section numbering
\setlength{\parindent}{0pt} % No indentation
\setlength{\topskip}{0pt} % No top skip
\pagenumbering{gobble} % No page numbering
\titleformat{\section}{\LARGE\color{primaryColor}}{}{}{\textbf{#1}\hspace{0.15cm}\titlerule[0.8pt]}[] % New section title format
\titlespacing{\section}{0pt}{\TopMarginOfSections}{\BottomMarginOfSections} % New section title spacing
% Date format (from: https://web.library.yale.edu/cataloging/months):
% \makeatletter
% \def\month@english{\ifcase\month\or
% Jan.\or Feb.\or Mar.\or Apr.\or May\or June\or
% July\or Aug.\or Sept.\or Oct.\or Nov.\or Dec.\fi}
% \makeatother
% \origdate
% New column types:
\newcolumntype{L}[1]{>{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}p{#1}}
\newcolumntype{R}[1]{>{\raggedleft\let\newline\\\arraybackslash\hspace{0pt}}p{#1}}
% New commands/environments:
\newenvironment{highlights}{\begin{itemize}[topsep=0pt, parsep=\YMarginBetweenBullets, partopsep=0pt, itemsep=0pt, after=\vspace*{-\baselineskip}, leftmargin=\LeftMarginOfBullets]}{\end{itemize}} % New environment for highlights
\newenvironment{header}[1][\topsep]{\setlength{\topsep}{#1}\par\kern\topsep\centering\color{primaryColor}\linespread{1.5}}{\par\kern\topsep} % New environment for the header
% New commands:
\newcommand{\hrefExternal}[2]{\href{#1}{#2\, \faExternalLink}}
\newcommand{\Header}[6]{
\begin{header}[0pt]
\Huge
\textbf{#1}
\normalsize
\faPhone\hspace{0.13cm}#2 \hspace{0.5cm}
\href{mailto:#3}{\faEnvelopeO\hspace{0.13cm}#3} \hspace{0.5cm}
\href{https://#4}{\faLaptop\hspace{0.13cm}#4} \hspace{0.5cm}
\href{https://www.linkedin.com/in/#5}{\faLinkedin\hspace{0.13cm}#5} \hspace{0.5cm}
\href{https://www.github.com/#6}{\faGithub\hspace{0.13cm}#6}
\end{header}
}
\newcommand{\EducationEntry}[8]{
\begin{tabularx}{\textwidth}{p{0.55cm} >{\raggedright}X R{\DateandLocationWidth}}
\textbf{#1} & \textbf{#2}, #3 \ifthenelse{\isempty{#6}}{}{\vspace{\YMarginBetweenBullets}\begin{highlights} \item #6 \ifthenelse{\isempty{#7}}{\end{highlights}}{\item #7 \ifthenelse{\isempty{#8}}{\end{highlights}}{\item #8 \end{highlights}}}} & \ifthenelse{\isempty{#4}}{#5}{#4\newline #5} \\
\end{tabularx}
\vspace{\YMarginBetweenEntries}
}
\newcommand{\ExperienceEntry}[8]{
\begin{tabularx}{\textwidth}{X R{\DateandLocationWidth}}
\textbf{#1}, #2 \ifthenelse{\isempty{#6}}{}{\vspace{\YMarginBetweenBullets}\begin{highlights} \item #6 \ifthenelse{\isempty{#7}}{\end{highlights}}{\item #7 \ifthenelse{\isempty{#8}}{\end{highlights}}{\item #8 \end{highlights}}}} & \ifthenelse{\isempty{#3}}{#4\newline #5}{#3\newline #4\newline #5} \\
\end{tabularx}
\vspace{\YMarginBetweenEntries}
}
\newcommand{\NormalEntry}[6]{
\begin{tabularx}{\textwidth}{X R{\DateandLocationWidth}}
\textbf{#1} \ifthenelse{\isempty{#4}}{}{\vspace{\YMarginBetweenBullets}\begin{highlights} \item #4 \ifthenelse{\isempty{#5}}{\end{highlights}}{\item #5 \ifthenelse{\isempty{#6}}{\end{highlights}}{\item #6 \end{highlights}}}} & \ifthenelse{\isempty{#2}}{#3}{#2\newline #3} \\
\end{tabularx}
\vspace{\YMarginBetweenEntries}
}
\newcommand{\OneLineEntry}[2]{
\setlength{\leftskip}{0.2cm}
\textbf{#1:} #2
\vspace{\YMarginBetweenEntries}
\setlength{\leftskip}{0cm}
}

BIN
rendercv/tinytex/test.pdf Normal file

Binary file not shown.

39
rendercv/tinytex/test.tex Normal file
View File

@ -0,0 +1,39 @@
\documentclass[10pt, a4paper]{memoir}
% ===========
% ===========
% USER INPUTS:
\newcommand{\AUTHOR}{Sina Atalay}
\newcommand{\PRIMARYCOLOR}{0,79,144} % In RGB out of 255
\newcommand{\PageXMargin}{0.53in}
\newcommand{\PageYMargin}{0.53in}
\newcommand{\TopMarginOfSections}{0.13cm}
\newcommand{\BottomMarginOfSections}{0.13cm}
\newcommand{\YMarginBetweenEntries}{0.12cm}
\newcommand{\YMarginBetweenBullets}{0.07cm}
\newcommand{\LeftMarginOfBullets}{0.7cm}
\newcommand{\DateandLocationWidth}{3.7cm}
% ===========
% ===========
\input{preamble}
\begin{document}
% Test out the 4 main entry types with the commands below:
\Header{a}{b}{c}{d}{e}{f}
\section{EducationEntry}
\EducationEntry{a}{b}{c}{d}{e}{f}{g}{j}
\section{ExperienceEntry}
\ExperienceEntry{a}{b}{c}{d}{e}{f}{g}{j}
\section{NormalEntry}
\NormalEntry{a}{b}{c}{d}{e}{f}
\section{OneLineEntry}
\OneLineEntry{a}{b}
\end{document}

40
rendercv/tinytex/vendor/README.md vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,99 @@
\usepackage[ignoreheadfoot, top=\PageYMargin, bottom=\PageYMargin, left=\PageXMargin, right=\PageXMargin, headsep=0.3cm]{geometry}
\usepackage{fontspec}
\usepackage[explicit]{titlesec}
\usepackage{tabularx}
\usepackage{array}
\usepackage{xifthen}
\usepackage[dvipsnames]{xcolor}
\definecolor{primaryColor}{RGB}{\PRIMARYCOLOR}
\usepackage{enumitem}
\usepackage{fontawesome}
\usepackage[pdftitle={\AUTHOR's CV}, pdfauthor={\AUTHOR}, colorlinks=true, urlcolor=primaryColor]{hyperref} % Linking
% \setmainfont{SourceSansPro}[
% Path= fonts/,
% Extension = .ttf,
% UprightFont = *-Regular,
% ItalicFont = *-Italic,
% BoldFont = *-Bold,
% BoldItalicFont = *-BoldItalic]
% Calculate last update top margin:
\newlength\A
\newlength\B
\setlength\A{\PageYMargin}
\setlength\B{\dimexpr \numexpr \A / 1 \relax sp\relax}
\setcounter{secnumdepth}{0} % No section numbering
\setlength{\parindent}{0pt} % No indentation
\setlength{\topskip}{0pt} % No top skip
\pagenumbering{gobble} % No page numbering
\titleformat{\section}{\LARGE\color{primaryColor}}{}{}{\textbf{#1}\hspace{0.15cm}\titlerule[0.8pt]}[] % New section title format
\titlespacing{\section}{0pt}{\TopMarginOfSections}{\BottomMarginOfSections} % New section title spacing
% Date format (from: https://web.library.yale.edu/cataloging/months):
% \makeatletter
% \def\month@english{\ifcase\month\or
% Jan.\or Feb.\or Mar.\or Apr.\or May\or June\or
% July\or Aug.\or Sept.\or Oct.\or Nov.\or Dec.\fi}
% \makeatother
% \origdate
% New column types:
\newcolumntype{L}[1]{>{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}p{#1}}
\newcolumntype{R}[1]{>{\raggedleft\let\newline\\\arraybackslash\hspace{0pt}}p{#1}}
% New commands/environments:
\newenvironment{highlights}{\begin{itemize}[topsep=0pt, parsep=\YMarginBetweenBullets, partopsep=0pt, itemsep=0pt, after=\vspace*{-\baselineskip}, leftmargin=\LeftMarginOfBullets]}{\end{itemize}} % New environment for highlights
\newenvironment{header}[1][\topsep]{\setlength{\topsep}{#1}\par\kern\topsep\centering\color{primaryColor}\linespread{1.5}}{\par\kern\topsep} % New environment for the header
% New commands:
\newcommand{\hrefExternal}[2]{\href{#1}{#2\, \faExternalLink}}
\newcommand{\Header}[6]{
\begin{header}[0pt]
\Huge
\textbf{#1}
\normalsize
\faPhone\hspace{0.13cm}#2 \hspace{0.5cm}
\href{mailto:#3}{\faEnvelopeO\hspace{0.13cm}#3} \hspace{0.5cm}
\href{https://#4}{\faLaptop\hspace{0.13cm}#4} \hspace{0.5cm}
\href{https://www.linkedin.com/in/#5}{\faLinkedin\hspace{0.13cm}#5} \hspace{0.5cm}
\href{https://www.github.com/#6}{\faGithub\hspace{0.13cm}#6}
\end{header}
}
\newcommand{\EducationEntry}[8]{
\begin{tabularx}{\textwidth}{p{0.55cm} >{\raggedright}X R{\DateandLocationWidth}}
\textbf{#1} & \textbf{#2}, #3 \ifthenelse{\isempty{#6}}{}{\vspace{\YMarginBetweenBullets}\begin{highlights} \item #6 \ifthenelse{\isempty{#7}}{\end{highlights}}{\item #7 \ifthenelse{\isempty{#8}}{\end{highlights}}{\item #8 \end{highlights}}}} & \ifthenelse{\isempty{#4}}{#5}{#4\newline #5} \\
\end{tabularx}
\vspace{\YMarginBetweenEntries}
}
\newcommand{\ExperienceEntry}[8]{
\begin{tabularx}{\textwidth}{X R{\DateandLocationWidth}}
\textbf{#1}, #2 \ifthenelse{\isempty{#6}}{}{\vspace{\YMarginBetweenBullets}\begin{highlights} \item #6 \ifthenelse{\isempty{#7}}{\end{highlights}}{\item #7 \ifthenelse{\isempty{#8}}{\end{highlights}}{\item #8 \end{highlights}}}} & \ifthenelse{\isempty{#3}}{#4\newline #5}{#3\newline #4\newline #5} \\
\end{tabularx}
\vspace{\YMarginBetweenEntries}
}
\newcommand{\NormalEntry}[6]{
\begin{tabularx}{\textwidth}{X R{\DateandLocationWidth}}
\textbf{#1} \ifthenelse{\isempty{#4}}{}{\vspace{\YMarginBetweenBullets}\begin{highlights} \item #4 \ifthenelse{\isempty{#5}}{\end{highlights}}{\item #5 \ifthenelse{\isempty{#6}}{\end{highlights}}{\item #6 \end{highlights}}}} & \ifthenelse{\isempty{#2}}{#3}{#2\newline #3} \\
\end{tabularx}
\vspace{\YMarginBetweenEntries}
}
\newcommand{\OneLineEntry}[2]{
\setlength{\leftskip}{0.2cm}
\textbf{#1:} #2
\vspace{\YMarginBetweenEntries}
\setlength{\leftskip}{0cm}
}

39
tests/outputs/test.tex Normal file
View File

@ -0,0 +1,39 @@
\documentclass[10pt, a4paper]{memoir}
% ===========
% ===========
% USER INPUTS:
\newcommand{\AUTHOR}{Sina Atalay}
\newcommand{\PRIMARYCOLOR}{0,79,144} % In RGB out of 255
\newcommand{\PageXMargin}{0.53in}
\newcommand{\PageYMargin}{0.53in}
\newcommand{\TopMarginOfSections}{0.13cm}
\newcommand{\BottomMarginOfSections}{0.13cm}
\newcommand{\YMarginBetweenEntries}{0.12cm}
\newcommand{\YMarginBetweenBullets}{0.07cm}
\newcommand{\LeftMarginOfBullets}{0.7cm}
\newcommand{\DateandLocationWidth}{3.7cm}
% ===========
% ===========
\input{preamble}
\begin{document}
% Test out the 4 main entry types with the commands below:
\Header{a}{b}{c}{d}{e}{f}
\section{EducationEntry}
\EducationEntry{a}{b}{c}{d}{e}{f}{g}{j}
\section{ExperienceEntry}
\ExperienceEntry{a}{b}{c}{d}{e}{f}{g}{j}
\section{NormalEntry}
\NormalEntry{a}{b}{c}{d}{e}{f}
\section{OneLineEntry}
\OneLineEntry{a}{b}
\end{document}