From dfa23b9fbb44f9aae53e9f16d60666c7a8e90da1 Mon Sep 17 00:00:00 2001 From: Sina Atalay Date: Sat, 24 Feb 2024 16:20:13 +0100 Subject: [PATCH] update docstrings --- rendercv/cli.py | 2 +- rendercv/data_models.py | 6 +++--- rendercv/renderer.py | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/rendercv/cli.py b/rendercv/cli.py index 3ad0ec5..849b4d8 100644 --- a/rendercv/cli.py +++ b/rendercv/cli.py @@ -411,7 +411,7 @@ def cli_command_render( help="Use the local LaTeX installation instead of the RenderCV's TinyTeX.", ), ): - """Generate a LaTeX CV from a YAML input file. + """Generate a $\\LaTeX$ CV from a YAML input file. Args: input_file_path (str): Path to the YAML input file as a string. diff --git a/rendercv/data_models.py b/rendercv/data_models.py index 0f1f77d..7a8d194 100644 --- a/rendercv/data_models.py +++ b/rendercv/data_models.py @@ -2,7 +2,7 @@ This module contains all the necessary classes to store CV data. These classes are called data models. The YAML input file is transformed into instances of these classes (i.e., the input file is read) with the [`read_input_file`](#read_input_file) function. -RenderCV utilizes these instances to generate a LaTeX file which is then rendered into a +RenderCV utilizes these instances to generate a $\\LaTeX$ file which is then rendered into a PDF file. The data models are initialized with data validation to prevent unexpected bugs. During @@ -1061,14 +1061,14 @@ def read_input_file( file_path: pathlib.Path, ) -> RenderCVDataModel: """Read the input file and return two instances of RenderCVDataModel. The first - instance is the data model with LaTeX strings and the second instance is the data + instance is the data model with $\\LaTeX$ strings and the second instance is the data model with markdown strings. Args: file_path (str): The path to the input file. Returns: - tuple[RenderCVDataModel, RenderCVDataModel]: The data models with LaTeX and + tuple[RenderCVDataModel, RenderCVDataModel]: The data models with $\\LaTeX$ and markdown strings. """ # check if the file exists: diff --git a/rendercv/renderer.py b/rendercv/renderer.py index b675d5f..ced5b7a 100644 --- a/rendercv/renderer.py +++ b/rendercv/renderer.py @@ -28,7 +28,7 @@ from . import data_models as dm class TemplatedFile: """This class is a base class for LaTeXFile and MarkdownFile classes. It contains the common methods and attributes for both classes. These classes are used to - generate the LaTeX and Markdown files with the data model and Jinja2 templates. + generate the $\\LaTeX$ and Markdown files with the data model and Jinja2 templates. Args: data_model (dm.RenderCVDataModel): The data model. @@ -411,7 +411,7 @@ def markdown_to_latex(markdown_string: str) -> str: markdown_string (str): The markdown string to convert. Returns: - str: The LaTeX string. + str: The $\\LaTeX$ string. """ # convert links links = re.findall(r"\[([^\]\[]*)\]\((.*?)\)", markdown_string) @@ -539,7 +539,7 @@ def make_matched_part_something( Args: value (str): The string to make something. - something (str): The LaTeX command to use. + something (str): The $\\LaTeX$ command to use. match_str (str): The string to match. Returns: str: The string with the matched part something.