cleanup comments

This commit is contained in:
ssalbdivad
2025-10-09 16:33:11 -04:00
parent f74a75cfac
commit 9459803aaa
11 changed files with 7 additions and 185 deletions
-6
View File
@@ -1,7 +1,6 @@
import * as core from "@actions/core";
import { ClaudeAgent } from "./agents/claude.ts";
// Expected environment variables that should be passed as inputs
export const EXPECTED_INPUTS: string[] = [
"ANTHROPIC_API_KEY",
"GITHUB_TOKEN",
@@ -29,24 +28,19 @@ export interface MainResult {
export async function main(params: MainParams): Promise<MainResult> {
try {
// Extract inputs from params
const { inputs, env, cwd } = params;
// Set working directory if different from current
if (cwd !== process.cwd()) {
process.chdir(cwd);
}
// Set environment variables
Object.assign(process.env, env);
core.info(`→ Starting agent run with Claude Code`);
// Create and install the Claude agent
const agent = new ClaudeAgent({ apiKey: inputs.anthropic_api_key });
await agent.install();
// Execute the agent with the prompt
const result = await agent.execute(inputs.prompt);
if (!result.success) {