Skip to content

Commit

Permalink
Create Analyze_pmll.py
Browse files Browse the repository at this point in the history
Signed-off-by: Josef Edwards <joed6834@colorado.edu>
  • Loading branch information
bearycool11 authored Nov 11, 2024
1 parent 63929c6 commit f62203f
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions Analyze_pmll.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import os
import re

def analyze_repository(repo_path):
analysis_report = []
for root, _, files in os.walk(repo_path):
for file in files:
if file.endswith('.py'): # Adjust for other file types as needed
with open(os.path.join(root, file), 'r') as f:
content = f.read()
# Example: Find function definitions
functions = re.findall(r'def (\w+)', content)
analysis_report.append((file, functions))
# Add custom analysis patterns or checks here
return analysis_report

# Path to your repository
repo_path = '/path/to/your/repository'
report = analyze_repository(repo_path)

# Print or save the report
for file, functions in report:
print(f"File: {file}")
print("Functions:", functions)

0 comments on commit f62203f

Please sign in to comment.