Created
March 22, 2026 01:58
-
-
Save jkoelker/1bf8a0f6dadb2205ad045310ed1b1a67 to your computer and use it in GitHub Desktop.
apply-opencode adapter selection
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| .iter() | |
| .map(|path| { | |
| path.strip_prefix(repo_dir) | |
| .map(|value| value.display().to_string()) | |
| .with_context(|| format!("{} did not live under repo root", path.display())) | |
| }) | |
| .collect() | |
| } | |
| fn apply_ticket_via_selected_adapter( | |
| ticket: &TicketDocument, | |
| ticket_path: &Path, | |
| repo_dir: &Path, | |
| worker_command: &str, | |
| ) -> anyhow::Result<PathBuf> { | |
| match worker_command { | |
| "apply-opencode" => apply_ticket_with_opencode(ticket_path, repo_dir), | |
| _ => apply_ticket(ticket_path, repo_dir), | |
| } | |
| .with_context(|| format!("{} failed for {}", worker_command, ticket.front_matter.id)) | |
| } | |
| fn verify_repo_changes_match_targets( | |
| repo_dir: &Path, | |
| allowed_targets: &[String], | |
| ) -> anyhow::Result<()> { |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment