Skip to content

Commit

Permalink
Changed names of CLI functions
Browse files Browse the repository at this point in the history
  • Loading branch information
JosePizarro3 committed Dec 18, 2024
1 parent 68536d1 commit 9058106
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions bam_masterdata/cli/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,11 @@ def cli():
pass


@cli.command(help='Export entities to JSON files to the `./artifacts/` folder.')
def export_entities_to_json():
@cli.command(
name='export_to_json',
help='Export entities to JSON files to the `./artifacts/` folder.',
)
def export_to_json():
# Get the directories from the Python modules and the export directory for the static artifacts
datamodel_dir = os.path.join('.', 'bam_masterdata', 'datamodel')
export_dir = os.path.join('.', 'artifacts')
Expand All @@ -38,11 +41,12 @@ def export_entities_to_json():


@cli.command(
name='export_to_excel',
help="""
Export entities to an Excel file in the path `./artifacts/masterdata.xlsx`.
""",
)
def export_entities_to_excel():
def export_to_excel():
# Get the Python modules to process the datamodel
datamodel_dir = os.path.join('.', 'bam_masterdata', 'datamodel')
py_modules = listdir_py_modules(directory_path=datamodel_dir, logger=logger)
Expand Down

1 comment on commit 9058106

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coverage

Coverage Report
FileStmtsMissCoverMissing
bam_masterdata
   logger.py80100% 
bam_masterdata/cli
   cli.py363636 0%
   entities_to_excel.py393939 0%
   entities_to_json.py353535 0%
bam_masterdata/datamodel
   collection_types.py777 0%
   dataset_types.py00100% 
   object_types.py111111 0%
   property_types.py222 0%
   vocabulary_types.py141414 0%
bam_masterdata/metadata
   definitions.py7844 95%
   entities.py4533 93%
bam_masterdata/utils
   utils.py331111 67%
TOTAL30816247% 

Tests Skipped Failures Errors Time
50 1 💤 0 ❌ 0 🔥 0.308s ⏱️

Please sign in to comment.