From 6ce5f9e49a3243d66deb88094ee443b1690542e2 Mon Sep 17 00:00:00 2001 From: ford prior Date: Mon, 14 Oct 2024 15:11:45 -0400 Subject: [PATCH] Update stats.py --- aws_doc_sdk_examples_tools/stats.py | 35 ----------------------------- 1 file changed, 35 deletions(-) diff --git a/aws_doc_sdk_examples_tools/stats.py b/aws_doc_sdk_examples_tools/stats.py index c6685f9..b18ec64 100644 --- a/aws_doc_sdk_examples_tools/stats.py +++ b/aws_doc_sdk_examples_tools/stats.py @@ -53,38 +53,3 @@ def collect_stats(roots: List[str]) -> List[Dict[str, Any]]: return all_stats -def print_stats(stats: Dict[str, Any]): - """ - Prints stats in a formatted manner. - - Args: - stats (dict): A dictionary containing collected stats. - """ - logging.info(f"Root: {stats['root']}") - logging.info(f"SDKs: {stats['sdks']}") - logging.info(f"Services: {stats['services']}") - logging.info(f"Examples: {stats['examples']}") - logging.info(f"Version: {stats['versions']}") - logging.info(f"Snippets: {stats['snippets']}") - genai = pformat(dict(stats.get("genai", {}))) - logging.info(f"GenAI: {genai}") - -def main(roots: List[str]): - """ - Collects stats for each root and prints results. - - Args: - roots (List[str]): A list of root directory paths as strings. - """ - all_stats = collect_stats(roots) - - for stats in all_stats: - print_stats(stats) - -if __name__ == "__main__": - from sys import argv - - if len(argv) < 2: - logging.error("No root directories provided. Usage: script.py ") - else: - main(argv[1:])