From 74cf3fc60272e0acba79823e1744e2f92ad66825 Mon Sep 17 00:00:00 2001 From: Sina Atalay Date: Sun, 3 Sep 2023 17:16:36 +0200 Subject: [PATCH] update folder structure of templates --- rendercv/templates/classic/classic.tex.j2 | 122 ++++++++++++++++++ .../{ => classic}/components/education.tex.j2 | 0 rendercv/templates/template1.tex.j2 | 83 ------------ 3 files changed, 122 insertions(+), 83 deletions(-) create mode 100644 rendercv/templates/classic/classic.tex.j2 rename rendercv/templates/{ => classic}/components/education.tex.j2 (100%) delete mode 100644 rendercv/templates/template1.tex.j2 diff --git a/rendercv/templates/classic/classic.tex.j2 b/rendercv/templates/classic/classic.tex.j2 new file mode 100644 index 0000000..48327a0 --- /dev/null +++ b/rendercv/templates/classic/classic.tex.j2 @@ -0,0 +1,122 @@ +\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} +% =========== +% =========== + +% ====================================================================================== +% ====================================================================================== +% ====================================================================================== +% Packages: +\usepackage[ + ignoreheadfoot, % set margins without considering header and footer + top=\PageYMargin, % seperation between body and page edge from the top + bottom=\PageYMargin, % seperation between body and page edge from the bottom + left=\PageXMargin, % seperation between body and page edge from the left + right=\PageXMargin, % seperation between body and page edge from the right + headsep=0.3cm % seperation between head and body + ]{geometry} % for adjusting page geometry +\usepackage{fontspec} % for loading fonts +\usepackage[explicit]{titlesec} % for customizing section titles +\usepackage{tabularx} % for making tables with fixed width columns +\usepackage{array} % for making tables with fixed width columns +\usepackage[dvipsnames]{xcolor} % for coloring text +\usepackage{fontawesome} % for using icons +\usepackage[ + pdftitle={(((cv.name)))'s CV}, + pdfauthor={(((cv.name)))}, + colorlinks=true, + urlcolor=primaryColor +]{hyperref} % for links, metadata and bookmarks +% ====================================================================================== +% ====================================================================================== +% ====================================================================================== + +% ====================================================================================== +% ====================================================================================== +% ====================================================================================== +% Some settings: +\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] + }[] % Section title formatting + +\titlespacing{\section}{ + 0pt + }{ + \TopMarginOfSections + }{ + \BottomMarginOfSections + } % Section title spacing + +\newcolumntype{L}[1]{ + >{\raggedright\let\newline\\\arraybackslash\hspace{0pt}}p{#1} +} % Left-aligned fixed width column type +\newcolumntype{R}[1]{ + >{\raggedleft\let\newline\\\arraybackslash\hspace{0pt}}p{#1} +} % Right-aligned fixed width column type + +\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 +% ====================================================================================== +% ====================================================================================== +% ====================================================================================== + + +\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} +} + +\begin{document} + % Test out the 4 main entry types with the commands below: + + \section{Education} + ((* set education = cv.education[0] *)) + \EducationEntry{(((education.institution)))}{(((education.area)))}{(((education.studyType)))}{(((education.startDate)))}{(((education.endDate)))}{(((education.gpa)))}{(((education.courses)))}{(((education.location)))} + \EducationEntry{a}{b}{c}{d}{e}{f}{g}{j} + + +\end{document} \ No newline at end of file diff --git a/rendercv/templates/components/education.tex.j2 b/rendercv/templates/classic/components/education.tex.j2 similarity index 100% rename from rendercv/templates/components/education.tex.j2 rename to rendercv/templates/classic/components/education.tex.j2 diff --git a/rendercv/templates/template1.tex.j2 b/rendercv/templates/template1.tex.j2 deleted file mode 100644 index 9d16b64..0000000 --- a/rendercv/templates/template1.tex.j2 +++ /dev/null @@ -1,83 +0,0 @@ -\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} - - % To create the header manually (insted of \Header command), use the code below: - % \begin{header}[0pt] - % \Huge - % \textbf{\directlua{tex.print(json.basics.name)}} - - % \normalsize - % \faPhone\hspace{0.13cm}\directlua{tex.print(json.basics.phone)} \hspace{0.5cm} - % \href{mailto:\directlua{tex.print(json.basics.email)}}{\faEnvelopeO\hspace{0.13cm}\directlua{tex.print(json.basics.email)}} \hspace{0.5cm} - % \href{https://\directlua{tex.print(json.basics.url)}}{\faLaptop\hspace{0.13cm}\directlua{tex.print(json.basics.url)}} \hspace{0.5cm} - % \href{https://www.linkedin.com/in/williamhgates}{\faLinkedin\hspace{0.13cm}williamhgates} \hspace{0.5cm} - % \href{https://www.github.com/sinaatalay}{\faGithub\hspace{0.13cm}sinaatalay} - % \end{header} - - \directlua{require("parser.lua")} - - \makeoddhead{headings}{}{}{\small\color{gray}\linespread{0}\emph{Last updated on {\printdayon\today}}\hspace*{0.2cm}} - \directlua{printHeader()} - - \section{Education} - ((* for education in data.education *)) - \EducationEntry{(((education.institution)))}{(((education.area)))}{(((education.studyType)))}{(((education.startDate)))}{(((education.endDate)))}{(((education.gpa)))}{(((education.courses)))}{(((education.location)))} - ((* endfor *)) - - \section{Work Experience} - \directlua{printExperience()} - - - \section{Academic Projects} - \directlua{printAcademicProjects()} - - \section{Certificates} - \directlua{printCertificates()} - - \section{Skills} - \directlua{printSkills()} - - \section{Test Scores} - \directlua{printTestScores()} - - \section{Personal Projects (test)} - \directlua{printPersonalProjects()} - - \section{Extracurricular Activities} - \directlua{printExtracurricularActivities()} - -\end{document} \ No newline at end of file