This commit is contained in:
Sina Atalay 2023-10-20 22:09:52 +02:00
parent 3cd0bc5ad1
commit bf85d31e90
3 changed files with 9 additions and 11 deletions

View File

@ -50,8 +50,6 @@ def new(name: Annotated[str, typer.Argument(help="Full name")]):
try: try:
environment = Environment( environment = Environment(
loader=PackageLoader("rendercv", os.path.join("templates")), loader=PackageLoader("rendercv", os.path.join("templates")),
trim_blocks=True,
lstrip_blocks=True,
) )
environment.variable_start_string = "<<" environment.variable_start_string = "<<"
environment.variable_end_string = ">>" environment.variable_end_string = ">>"

View File

@ -349,9 +349,9 @@ class ClassicThemeSectionTitleMargins(BaseModel):
class ClassicThemeEntryAreaMargins(BaseModel): class ClassicThemeEntryAreaMargins(BaseModel):
"""This class stores the margins of entry areas for the classic theme. """This class stores the margins of entry areas for the classic theme.
For the classic theme, entry areas are [OneLineEntry](../index.md#onelineentry), For the classic theme, entry areas are [OneLineEntry](../user_guide.md#onelineentry),
[NormalEntry](../index.md#normalentry), and [NormalEntry](../user_guide.md#normalentry), and
[ExperienceEntry](../index.md#experienceentry). [ExperienceEntry](../user_guide.md#experienceentry).
""" """
left: LaTeXDimension = Field( left: LaTeXDimension = Field(
@ -794,7 +794,7 @@ class Event(BaseModel):
class OneLineEntry(Event): class OneLineEntry(Event):
"""This class stores [OneLineEntry](../index.md#onelineentry) information.""" """This class stores [OneLineEntry](../user_guide.md#onelineentry) information."""
name: str = Field( name: str = Field(
title="Name", title="Name",
@ -807,7 +807,7 @@ class OneLineEntry(Event):
class NormalEntry(Event): class NormalEntry(Event):
"""This class stores [NormalEntry](../index.md#normalentry) information.""" """This class stores [NormalEntry](../user_guide.md#normalentry) information."""
name: str = Field( name: str = Field(
title="Name", title="Name",
@ -816,7 +816,7 @@ class NormalEntry(Event):
class ExperienceEntry(Event): class ExperienceEntry(Event):
"""This class stores [ExperienceEntry](../index.md#experienceentry) information.""" """This class stores [ExperienceEntry](../user_guide.md#experienceentry) information."""
company: str = Field( company: str = Field(
title="Company", title="Company",
@ -829,7 +829,7 @@ class ExperienceEntry(Event):
class EducationEntry(Event): class EducationEntry(Event):
"""This class stores [EducationEntry](../index.md#educationentry) information.""" """This class stores [EducationEntry](../user_guide.md#educationentry) information."""
institution: str = Field( institution: str = Field(
title="Institution", title="Institution",
@ -878,7 +878,7 @@ class EducationEntry(Event):
class PublicationEntry(Event): class PublicationEntry(Event):
"""This class stores [PublicationEntry](../index.md#publicationentry) information.""" """This class stores [PublicationEntry](../user_guide.md#publicationentry) information."""
title: str = Field( title: str = Field(
title="Title of the Publication", title="Title of the Publication",

View File

@ -333,7 +333,7 @@ def render_template(data: RenderCVDataModel, output_path: Optional[str] = None)
file_name = data.cv.name.replace(" ", "_") + "_CV.tex" file_name = data.cv.name.replace(" ", "_") + "_CV.tex"
output_file_path = os.path.join(output_folder, file_name) output_file_path = os.path.join(output_folder, file_name)
os.makedirs(os.path.dirname(output_file_path), exist_ok=True) os.makedirs(os.path.dirname(output_file_path), exist_ok=True)
with open(output_file_path, "w", encoding="utf-8") as file: with open(output_file_path, "w") as file:
file.write(output_latex_file) file.write(output_latex_file)
# Copy the fonts directory to the output directory: # Copy the fonts directory to the output directory: