From 850441ca648ed1e159fdf0579390f4b4fee8fa85 Mon Sep 17 00:00:00 2001 From: Achintha Isuru Date: Tue, 2 Dec 2025 23:49:17 -0500 Subject: [PATCH] feat: Add a comprehensive development plan for new mobile app features and infrastructure, updating issue creation tooling. --- Makefile | 2 +- issues-to-create.md | 18 ++++++++++++++++++ scripts/create_issues.py | 22 ++++++++++++++++++---- 3 files changed, 37 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 8910eb11..13a37fba 100644 --- a/Makefile +++ b/Makefile @@ -292,7 +292,7 @@ export-issues: create-issues-from-file: @echo "--> Creating GitHub issues from file..." - @./scripts/create_issues.py + @./scripts/create_issues.py $(ARGS) # --- Development Tools --- install-git-hooks: diff --git a/issues-to-create.md b/issues-to-create.md index e69de29b..b2625354 100644 --- a/issues-to-create.md +++ b/issues-to-create.md @@ -0,0 +1,18 @@ +# 🚀 [CATEGORY] +Labels: , , , sred-eligible + +### 🎯 Objective + + +### 🔬 SR&ED Justification + +#### Technological Uncertainty + + +#### Systematic Investigation + + +### ✅ Acceptance Criteria +- [ ] +- [ ] +- [ ] diff --git a/scripts/create_issues.py b/scripts/create_issues.py index 70b8e20e..16727829 100755 --- a/scripts/create_issues.py +++ b/scripts/create_issues.py @@ -2,18 +2,21 @@ import subprocess import os import re +import argparse # --- Configuration --- INPUT_FILE = "issues-to-create.md" -PROJECT_TITLE = "Krow" +DEFAULT_PROJECT_TITLE = "Krow" # --- -def create_issue(title, body, labels, milestone): +def create_issue(title, body, labels, milestone, project_title=None): """Creates a GitHub issue using the gh CLI.""" command = ["gh", "issue", "create"] command.extend(["--title", title]) command.extend(["--body", body]) - command.extend(["--project", PROJECT_TITLE]) + + if project_title: + command.extend(["--project", project_title]) if milestone: command.extend(["--milestone", milestone]) @@ -33,7 +36,18 @@ def create_issue(title, body, labels, milestone): def main(): """Main function to parse the file and create issues.""" + parser = argparse.ArgumentParser(description="Bulk create GitHub issues from a markdown file.") + parser.add_argument("--project", default=DEFAULT_PROJECT_TITLE, help="GitHub Project title to add issues to.") + parser.add_argument("--no-project", action="store_true", help="Do not add issues to any project.") + args = parser.parse_args() + + project_title = args.project if not args.no_project else None + print(f"🚀 Starting bulk creation of GitHub issues from '{INPUT_FILE}'...") + if project_title: + print(f" Target Project: '{project_title}'") + else: + print(" Target Project: (None)") if subprocess.run(["which", "gh"], capture_output=True).returncode != 0: print("❌ ERROR: GitHub CLI (‘gh’) is not installed.") @@ -84,7 +98,7 @@ def main(): print("⚠️ Skipping block with no title.") continue - create_issue(title, body, labels, milestone) + create_issue(title, body, labels, milestone, project_title) print("\n🎉 Bulk issue creation complete!")