Class: Aidp::IssueImporter
- Inherits:
-
Object
- Object
- Aidp::IssueImporter
- Includes:
- MessageDisplay
- Defined in:
- lib/aidp/cli/issue_importer.rb
Overview
Handles importing GitHub issues into AIDP work loops
Constant Summary collapse
- COMPONENT =
"issue_importer"
Constants included from MessageDisplay
Instance Method Summary collapse
- #import_issue(identifier) ⇒ Object
-
#initialize(gh_available: nil, enable_bootstrap: true) ⇒ IssueImporter
constructor
Initialize the importer.
Methods included from MessageDisplay
#display_message, included, #message_display_prompt
Constructor Details
#initialize(gh_available: nil, enable_bootstrap: true) ⇒ IssueImporter
Initialize the importer
22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/aidp/cli/issue_importer.rb', line 22 def initialize(gh_available: nil, enable_bootstrap: true) disabled_via_env = ENV["AIDP_DISABLE_GH_CLI"] == "1" @gh_available = if disabled_via_env false else gh_available.nil? ? gh_cli_available? : gh_available end @enable_bootstrap = enable_bootstrap Aidp.log_debug(COMPONENT, "Initialized importer", gh_available: @gh_available, enable_bootstrap: @enable_bootstrap, disabled_via_env: disabled_via_env) Aidp.log_debug(COMPONENT, "GitHub CLI disabled via env flag") if disabled_via_env end |
Instance Method Details
#import_issue(identifier) ⇒ Object
34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/aidp/cli/issue_importer.rb', line 34 def import_issue(identifier) issue_url = normalize_issue_identifier(identifier) return nil unless issue_url issue_data = fetch_issue_data(issue_url) return nil unless issue_data display_imported_issue(issue_data) create_work_loop_prompt(issue_data) perform_bootstrap(issue_data) issue_data end |