Skip to content

Commit

Permalink
uppercase CONFIG_PATH and docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
TeaganKing committed May 8, 2024
1 parent ecd517f commit 0eec99b
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions cupid/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
Jupyter book using the `jupyter-book` command-line tool.
Args:
config_path: str, path to configuration file (default config.yml)
CONFIG_PATH: str, path to configuration file (default config.yml)
Returns:
None
Expand All @@ -25,10 +25,10 @@
@click.argument("config_path", default="config.yml")
def build(config_path):
"""
Build a Jupyter book based on the TOC in config.yml. Called by `cupid-build`.
Build a Jupyter book based on the TOC in CONFIG_PATH. Called by `cupid-build`.
Args:
config_path: str, path to configuration file (default config.yml)
CONFIG_PATH: str, path to configuration file (default config.yml)
Returns:
None
Expand Down
14 changes: 7 additions & 7 deletions cupid/clear.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#!/usr/bin/env python
"""
This script provides functionality to clear the contents of the 'computed_notebooks' folder
at the location specified by the 'run_dir' variable in the 'config.yml' file.
at the location specified by the 'run_dir' variable in the CONFIG_PATH.
The main function `clear()` takes the path to the config.yml file as input, reads the config file
The main function `clear()` takes the path to the configuration file as input, reads the config file
to obtain the 'run_dir' variable, and then deletes the contents of the 'computed_notebooks' folder
at that location.
Expand All @@ -17,16 +17,16 @@

def read_config_file(config_path):
"""
Given the file path to config.yml, this function reads the config file content and
Given the file path to the configuration file, this function reads the config file content and
returns the val of the run_dir string with '/computed_notebooks' appended to it
Args:
config_path: str, path to configuration file (default config.yml)
CONFIG_PATH: str, path to configuration file (default config.yml)
Returns:
None
"""
# Obtain the contents of the config.yml file and extract the run_dir variable
# Obtain the contents of the configuration file and extract the run_dir variable
control = cupid.util.get_control_dict(config_path)
run_dir = control["data_sources"].get("run_dir", None)

Expand All @@ -44,9 +44,9 @@ def read_config_file(config_path):
# Entry point to this script
def clear(config_path):
"""Clears the contents of the 'computed_notebooks' folder at the location
specified by the 'run_dir' variable in the 'config.yml' file.
specified by the 'run_dir' variable in the CONFIG_PATH.
Args: config_path - The path to the config.yml file.
Args: CONFIG_PATH - The path to the configuration file.
"""

Expand Down
2 changes: 1 addition & 1 deletion cupid/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def run(
Main engine to set up running all the notebooks.
Args:
config_path: str, path to configuration file (default config.yml)
CONFIG_PATH: str, path to configuration file (default config.yml)
Returns:
None
Expand Down

0 comments on commit 0eec99b

Please sign in to comment.