diff --git a/.github/workflows/audit-workflows.lock.yml b/.github/workflows/audit-workflows.lock.yml index e68021913bf..63879acaf2f 100644 --- a/.github/workflows/audit-workflows.lock.yml +++ b/.github/workflows/audit-workflows.lock.yml @@ -310,7 +310,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2424,7 +2424,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Agentic Workflow Audit Agent", experimental: false, supports_tools_allowlist: true, @@ -4723,7 +4723,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/blog-auditor.lock.yml b/.github/workflows/blog-auditor.lock.yml index 74e65e8ddac..7ae318f47e0 100644 --- a/.github/workflows/blog-auditor.lock.yml +++ b/.github/workflows/blog-auditor.lock.yml @@ -232,7 +232,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1742,7 +1742,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Blog Auditor", experimental: false, supports_tools_allowlist: true, @@ -4067,7 +4067,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/commit-changes-analyzer.lock.yml b/.github/workflows/commit-changes-analyzer.lock.yml index 94cbf70c1c5..f3c194284fd 100644 --- a/.github/workflows/commit-changes-analyzer.lock.yml +++ b/.github/workflows/commit-changes-analyzer.lock.yml @@ -235,7 +235,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1709,7 +1709,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Commit Changes Analyzer", experimental: false, supports_tools_allowlist: true, @@ -3997,7 +3997,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/copilot-agent-analysis.lock.yml b/.github/workflows/copilot-agent-analysis.lock.yml index 4e08eee1787..56bafb7c169 100644 --- a/.github/workflows/copilot-agent-analysis.lock.yml +++ b/.github/workflows/copilot-agent-analysis.lock.yml @@ -265,7 +265,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2041,7 +2041,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Copilot Agent PR Analysis", experimental: false, supports_tools_allowlist: true, @@ -4350,7 +4350,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/copilot-session-insights.lock.yml b/.github/workflows/copilot-session-insights.lock.yml index 5fb0ee3cfc6..a39a8756f42 100644 --- a/.github/workflows/copilot-session-insights.lock.yml +++ b/.github/workflows/copilot-session-insights.lock.yml @@ -305,7 +305,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2971,7 +2971,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Copilot Session Insights", experimental: false, supports_tools_allowlist: true, @@ -5271,7 +5271,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/daily-doc-updater.lock.yml b/.github/workflows/daily-doc-updater.lock.yml index 3e5746f5e69..a6db26f5524 100644 --- a/.github/workflows/daily-doc-updater.lock.yml +++ b/.github/workflows/daily-doc-updater.lock.yml @@ -250,7 +250,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1614,7 +1614,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Daily Documentation Updater", experimental: false, supports_tools_allowlist: true, @@ -4315,7 +4315,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/developer-docs-consolidator.lock.yml b/.github/workflows/developer-docs-consolidator.lock.yml index 58b593a9429..f1ec1485996 100644 --- a/.github/workflows/developer-docs-consolidator.lock.yml +++ b/.github/workflows/developer-docs-consolidator.lock.yml @@ -285,7 +285,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2158,7 +2158,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Developer Documentation Consolidator", experimental: false, supports_tools_allowlist: true, @@ -5106,7 +5106,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/example-workflow-analyzer.lock.yml b/.github/workflows/example-workflow-analyzer.lock.yml index 328c63619ed..19faf15e0d8 100644 --- a/.github/workflows/example-workflow-analyzer.lock.yml +++ b/.github/workflows/example-workflow-analyzer.lock.yml @@ -234,7 +234,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1499,7 +1499,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Weekly Workflow Analysis", experimental: false, supports_tools_allowlist: true, @@ -3781,7 +3781,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/github-mcp-tools-report.lock.yml b/.github/workflows/github-mcp-tools-report.lock.yml index cdb08a72b45..2174bf888a6 100644 --- a/.github/workflows/github-mcp-tools-report.lock.yml +++ b/.github/workflows/github-mcp-tools-report.lock.yml @@ -265,7 +265,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1986,7 +1986,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "GitHub MCP Remote Server Tools Report Generator", experimental: false, supports_tools_allowlist: true, @@ -4942,7 +4942,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/go-logger.lock.yml b/.github/workflows/go-logger.lock.yml index 02f50a0ec23..386bcf7c191 100644 --- a/.github/workflows/go-logger.lock.yml +++ b/.github/workflows/go-logger.lock.yml @@ -267,7 +267,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1729,7 +1729,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Go Logger Enhancement", experimental: false, supports_tools_allowlist: true, @@ -4420,7 +4420,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/go-pattern-detector.lock.yml b/.github/workflows/go-pattern-detector.lock.yml index 87f51284fe1..4ff221c5d3a 100644 --- a/.github/workflows/go-pattern-detector.lock.yml +++ b/.github/workflows/go-pattern-detector.lock.yml @@ -237,7 +237,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1542,7 +1542,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Go Pattern Detector", experimental: false, supports_tools_allowlist: true, @@ -3904,7 +3904,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/instructions-janitor.lock.yml b/.github/workflows/instructions-janitor.lock.yml index 43236769b4d..ba980148756 100644 --- a/.github/workflows/instructions-janitor.lock.yml +++ b/.github/workflows/instructions-janitor.lock.yml @@ -250,7 +250,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1612,7 +1612,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Instructions Janitor", experimental: false, supports_tools_allowlist: true, @@ -4299,7 +4299,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/lockfile-stats.lock.yml b/.github/workflows/lockfile-stats.lock.yml index 1ee5777c072..52cb12a9418 100644 --- a/.github/workflows/lockfile-stats.lock.yml +++ b/.github/workflows/lockfile-stats.lock.yml @@ -254,7 +254,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1835,7 +1835,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Lockfile Statistics Analysis Agent", experimental: false, supports_tools_allowlist: true, @@ -4134,7 +4134,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/prompt-clustering-analysis.lock.yml b/.github/workflows/prompt-clustering-analysis.lock.yml index 527302b31c9..e3ec38be689 100644 --- a/.github/workflows/prompt-clustering-analysis.lock.yml +++ b/.github/workflows/prompt-clustering-analysis.lock.yml @@ -303,7 +303,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2181,7 +2181,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Copilot Agent Prompt Clustering Analysis", experimental: false, supports_tools_allowlist: true, @@ -4470,7 +4470,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/safe-output-health.lock.yml b/.github/workflows/safe-output-health.lock.yml index 82304b99e24..025273e565c 100644 --- a/.github/workflows/safe-output-health.lock.yml +++ b/.github/workflows/safe-output-health.lock.yml @@ -280,7 +280,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1964,7 +1964,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Safe Output Health Monitor", experimental: false, supports_tools_allowlist: true, @@ -4266,7 +4266,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/schema-consistency-checker.lock.yml b/.github/workflows/schema-consistency-checker.lock.yml index 5d0f54942a7..bb43a53e64d 100644 --- a/.github/workflows/schema-consistency-checker.lock.yml +++ b/.github/workflows/schema-consistency-checker.lock.yml @@ -258,7 +258,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1845,7 +1845,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Schema Consistency Checker", experimental: false, supports_tools_allowlist: true, @@ -4137,7 +4137,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/scout.lock.yml b/.github/workflows/scout.lock.yml index d6cf4010ade..be5a327c375 100644 --- a/.github/workflows/scout.lock.yml +++ b/.github/workflows/scout.lock.yml @@ -1297,7 +1297,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2885,7 +2885,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Scout", experimental: false, supports_tools_allowlist: true, @@ -4942,7 +4942,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/security-fix-pr.lock.yml b/.github/workflows/security-fix-pr.lock.yml index d307bd87d95..003891d897f 100644 --- a/.github/workflows/security-fix-pr.lock.yml +++ b/.github/workflows/security-fix-pr.lock.yml @@ -248,7 +248,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1583,7 +1583,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Security Fix PR", experimental: false, supports_tools_allowlist: true, @@ -4261,7 +4261,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/semantic-function-refactor.lock.yml b/.github/workflows/semantic-function-refactor.lock.yml index 994602cf667..17e42fcbd77 100644 --- a/.github/workflows/semantic-function-refactor.lock.yml +++ b/.github/workflows/semantic-function-refactor.lock.yml @@ -257,7 +257,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1921,7 +1921,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Semantic Function Refactoring", experimental: false, supports_tools_allowlist: true, @@ -4310,7 +4310,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/smoke-claude.lock.yml b/.github/workflows/smoke-claude.lock.yml index 975c1bd1933..54711f8fcbb 100644 --- a/.github/workflows/smoke-claude.lock.yml +++ b/.github/workflows/smoke-claude.lock.yml @@ -242,7 +242,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1508,7 +1508,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Smoke Claude", experimental: false, supports_tools_allowlist: true, @@ -3870,7 +3870,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/smoke-detector.lock.yml b/.github/workflows/smoke-detector.lock.yml index 13aba00f0a9..2a2e2a02ce8 100644 --- a/.github/workflows/smoke-detector.lock.yml +++ b/.github/workflows/smoke-detector.lock.yml @@ -1049,7 +1049,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2562,7 +2562,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Smoke Detector - Smoke Test Failure Investigator", experimental: false, supports_tools_allowlist: true, @@ -4929,7 +4929,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/static-analysis-report.lock.yml b/.github/workflows/static-analysis-report.lock.yml index b6c1a0c864f..482da2f06be 100644 --- a/.github/workflows/static-analysis-report.lock.yml +++ b/.github/workflows/static-analysis-report.lock.yml @@ -273,7 +273,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1869,7 +1869,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Static Analysis Report", experimental: false, supports_tools_allowlist: true, @@ -4155,7 +4155,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/super-linter-report.lock.yml b/.github/workflows/super-linter-report.lock.yml index bbaf2c91960..806c2d1a4f3 100644 --- a/.github/workflows/super-linter-report.lock.yml +++ b/.github/workflows/super-linter-report.lock.yml @@ -15,7 +15,9 @@ # create_issue["create_issue"] # detection["detection"] # missing_tool["missing_tool"] +# super_linter["super_linter"] # activation --> agent +# super_linter --> agent # agent --> create_issue # detection --> create_issue # agent --> detection @@ -145,7 +147,9 @@ jobs: }); agent: - needs: activation + needs: + - activation + - super_linter runs-on: ubuntu-latest permissions: actions: read @@ -160,58 +164,16 @@ jobs: output: ${{ steps.collect_output.outputs.output }} output_types: ${{ steps.collect_output.outputs.output_types }} steps: - - name: Checkout Code + - name: Checkout repository uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 with: + persist-credentials: false fetch-depth: 0 - - name: Set up Go - uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 - with: - cache: true - go-version-file: go.mod - - name: Set up Node.js - uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 - with: - cache: npm - cache-dependency-path: pkg/workflow/js/package-lock.json - node-version: "24" - - name: Install Dependencies - run: | - go mod download - cd pkg/workflow/js && npm ci - - continue-on-error: true - env: - CREATE_LOG_FILE: true - DEFAULT_BRANCH: main - FILTER_REGEX_EXCLUDE: dist/**/* - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - LINTER_RULES_PATH: . - LOG_FILE: /tmp/gh-aw/super-linter.log - VALIDATE_ALL_CODEBASE: true - VALIDATE_BASH: true - VALIDATE_GITHUB_ACTIONS: true - VALIDATE_GO: false - VALIDATE_GO_MODULES: false - VALIDATE_JAVASCRIPT_ES: false - VALIDATE_JSCPD: false - VALIDATE_JSON: false - VALIDATE_MARKDOWN: true - VALIDATE_SHELL_SHFMT: true - VALIDATE_TYPESCRIPT_ES: false - VALIDATE_YAML: true - id: super-linter - name: Run Super Linter - uses: super-linter/super-linter/slim@f6d06a003575dde14f917e642302cf1251f28f4a - - id: check-results - name: Check for linting issues - run: "if [ -f \"/tmp/gh-aw/super-linter.log\" ] && [ -s \"/tmp/gh-aw/super-linter.log\" ]; then\n # Check if there are actual errors (not just the header)\n if grep -qE \"ERROR|WARN|FAIL\" /tmp/gh-aw/super-linter.log; then\n echo \"needs-linting=true\" >> $GITHUB_OUTPUT\n else\n echo \"needs-linting=false\" >> $GITHUB_OUTPUT\n fi\nelse\n echo \"needs-linting=false\" >> $GITHUB_OUTPUT\nfi\n" - - if: always() - name: Upload linter log - uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 + - name: Download super-linter log + uses: actions/download-artifact@634f93cb2916e3fdff6788551b99b062d0335ce0 with: name: super-linter-log - path: /tmp/gh-aw/super-linter.log - retention-days: 7 + path: /tmp/gh-aw/ - name: Create gh-aw temp directory run: | @@ -4541,3 +4503,69 @@ jobs: core.setFailed(`Error processing missing-tool reports: ${error}`); }); + super_linter: + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 + with: + fetch-depth: 0 + - name: Set up Go + uses: actions/setup-go@44694675825211faa026b3c33043df3e48a5fa00 + with: + cache: true + go-version-file: go.mod + - name: Set up Node.js + uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 + with: + cache: npm + cache-dependency-path: pkg/workflow/js/package-lock.json + node-version: "24" + - name: Install Dependencies + run: | + go mod download + cd pkg/workflow/js && npm ci + - name: Run Super Linter + id: super-linter + uses: super-linter/super-linter/slim@f6d06a003575dde14f917e642302cf1251f28f4a + env: + CREATE_LOG_FILE: "true" + DEFAULT_BRANCH: main + FILTER_REGEX_EXCLUDE: dist/**/* + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + LINTER_RULES_PATH: . + LOG_FILE: /tmp/gh-aw/super-linter.log + VALIDATE_ALL_CODEBASE: "true" + VALIDATE_BASH: "true" + VALIDATE_GITHUB_ACTIONS: "true" + VALIDATE_GO: "false" + VALIDATE_GO_MODULES: "false" + VALIDATE_JAVASCRIPT_ES: "false" + VALIDATE_JSCPD: "false" + VALIDATE_JSON: "false" + VALIDATE_MARKDOWN: "true" + VALIDATE_SHELL_SHFMT: "true" + VALIDATE_TYPESCRIPT_ES: "false" + VALIDATE_YAML: "true" + continue-on-error: true + - name: Check for linting issues + id: check-results + run: | + if [ -f "/tmp/gh-aw/super-linter.log" ] && [ -s "/tmp/gh-aw/super-linter.log" ]; then + # Check if there are actual errors (not just the header) + if grep -qE "ERROR|WARN|FAIL" /tmp/gh-aw/super-linter.log; then + echo "needs-linting=true" >> $GITHUB_OUTPUT + else + echo "needs-linting=false" >> $GITHUB_OUTPUT + fi + else + echo "needs-linting=false" >> $GITHUB_OUTPUT + fi + - name: Upload super-linter log + if: always() + uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 + with: + name: super-linter-log + path: /tmp/gh-aw/super-linter.log + retention-days: 7 + diff --git a/.github/workflows/super-linter-report.md b/.github/workflows/super-linter-report.md index b84b1e18983..5b3d6d974f1 100644 --- a/.github/workflows/super-linter-report.md +++ b/.github/workflows/super-linter-report.md @@ -17,76 +17,85 @@ name: Super Linter Report timeout-minutes: 15 imports: - shared/reporting.md +jobs: + super_linter: + runs-on: ubuntu-latest + steps: + - name: Checkout Code + uses: actions/checkout@v5 + with: + fetch-depth: 0 + + - name: Set up Go + uses: actions/setup-go@v6 + with: + go-version-file: go.mod + cache: true + + - name: Set up Node.js + uses: actions/setup-node@v6 + with: + node-version: "24" + cache: npm + cache-dependency-path: pkg/workflow/js/package-lock.json + + - name: Install Dependencies + run: | + go mod download + cd pkg/workflow/js && npm ci + + - name: Run Super Linter + id: super-linter + continue-on-error: true + uses: super-linter/super-linter/slim@v8 + env: + DEFAULT_BRANCH: main + FILTER_REGEX_EXCLUDE: dist/**/* + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + LINTER_RULES_PATH: . + VALIDATE_ALL_CODEBASE: "true" + # Disable linters that are covered by other workflows or not applicable + VALIDATE_GO: "false" # golangci-lint is used instead in CI + VALIDATE_GO_MODULES: "false" # Go mod verification in CI + VALIDATE_JAVASCRIPT_ES: "false" # ESLint/npm test handles JS linting + VALIDATE_TYPESCRIPT_ES: "false" # Not using TypeScript + VALIDATE_JSCPD: "false" # Copy-paste detection not required + VALIDATE_JSON: "false" # Not strictly enforced + VALIDATE_GITHUB_ACTIONS: "true" # Keep GitHub Actions validation + VALIDATE_MARKDOWN: "true" # Keep Markdown validation + VALIDATE_YAML: "true" # Keep YAML validation + VALIDATE_SHELL_SHFMT: "true" # Keep shell script formatting + VALIDATE_BASH: "true" # Keep bash validation + LOG_FILE: /tmp/gh-aw/super-linter.log + CREATE_LOG_FILE: "true" + + - name: Check for linting issues + id: check-results + run: | + if [ -f "/tmp/gh-aw/super-linter.log" ] && [ -s "/tmp/gh-aw/super-linter.log" ]; then + # Check if there are actual errors (not just the header) + if grep -qE "ERROR|WARN|FAIL" /tmp/gh-aw/super-linter.log; then + echo "needs-linting=true" >> $GITHUB_OUTPUT + else + echo "needs-linting=false" >> $GITHUB_OUTPUT + fi + else + echo "needs-linting=false" >> $GITHUB_OUTPUT + fi + + - name: Upload super-linter log + if: always() + uses: actions/upload-artifact@v4 + with: + name: super-linter-log + path: /tmp/gh-aw/super-linter.log + retention-days: 7 steps: - - name: Checkout Code - uses: actions/checkout@v5 - with: - fetch-depth: 0 - - - name: Set up Go - uses: actions/setup-go@v6 - with: - go-version-file: go.mod - cache: true - - - name: Set up Node.js - uses: actions/setup-node@v6 - with: - node-version: "24" - cache: npm - cache-dependency-path: pkg/workflow/js/package-lock.json - - - name: Install Dependencies - run: | - go mod download - cd pkg/workflow/js && npm ci - - - name: Run Super Linter - id: super-linter - continue-on-error: true - uses: super-linter/super-linter/slim@v8 - env: - DEFAULT_BRANCH: main - FILTER_REGEX_EXCLUDE: dist/**/* - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - LINTER_RULES_PATH: . - VALIDATE_ALL_CODEBASE: true - # Disable linters that are covered by other workflows or not applicable - VALIDATE_GO: false # golangci-lint is used instead in CI - VALIDATE_GO_MODULES: false # Go mod verification in CI - VALIDATE_JAVASCRIPT_ES: false # ESLint/npm test handles JS linting - VALIDATE_TYPESCRIPT_ES: false # Not using TypeScript - VALIDATE_JSCPD: false # Copy-paste detection not required - VALIDATE_JSON: false # Not strictly enforced - VALIDATE_GITHUB_ACTIONS: true # Keep GitHub Actions validation - VALIDATE_MARKDOWN: true # Keep Markdown validation - VALIDATE_YAML: true # Keep YAML validation - VALIDATE_SHELL_SHFMT: true # Keep shell script formatting - VALIDATE_BASH: true # Keep bash validation - LOG_FILE: /tmp/gh-aw/super-linter.log - CREATE_LOG_FILE: true - - - name: Check for linting issues - id: check-results - run: | - if [ -f "/tmp/gh-aw/super-linter.log" ] && [ -s "/tmp/gh-aw/super-linter.log" ]; then - # Check if there are actual errors (not just the header) - if grep -qE "ERROR|WARN|FAIL" /tmp/gh-aw/super-linter.log; then - echo "needs-linting=true" >> $GITHUB_OUTPUT - else - echo "needs-linting=false" >> $GITHUB_OUTPUT - fi - else - echo "needs-linting=false" >> $GITHUB_OUTPUT - fi - - - name: Upload linter log - if: always() - uses: actions/upload-artifact@v4 + - name: Download super-linter log + uses: actions/download-artifact@v4 with: name: super-linter-log - path: /tmp/gh-aw/super-linter.log - retention-days: 7 + path: /tmp/gh-aw/ tools: cache-memory: true edit: diff --git a/.github/workflows/test-claude-oauth-workflow.lock.yml b/.github/workflows/test-claude-oauth-workflow.lock.yml index 3bbf0aba52d..6c599d7b791 100644 --- a/.github/workflows/test-claude-oauth-workflow.lock.yml +++ b/.github/workflows/test-claude-oauth-workflow.lock.yml @@ -217,7 +217,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -543,7 +543,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "test-claude-oauth", experimental: false, supports_tools_allowlist: true, diff --git a/.github/workflows/typist.lock.yml b/.github/workflows/typist.lock.yml index af2443f5d3f..4f73b5679c3 100644 --- a/.github/workflows/typist.lock.yml +++ b/.github/workflows/typist.lock.yml @@ -257,7 +257,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -1990,7 +1990,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Typist - Go Type Analysis", experimental: false, supports_tools_allowlist: true, @@ -4297,7 +4297,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/.github/workflows/unbloat-docs.lock.yml b/.github/workflows/unbloat-docs.lock.yml index 4f9507188a0..5441945e2be 100644 --- a/.github/workflows/unbloat-docs.lock.yml +++ b/.github/workflows/unbloat-docs.lock.yml @@ -1036,7 +1036,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Generate Claude Settings run: | mkdir -p /tmp/gh-aw/.claude @@ -2587,7 +2587,7 @@ jobs: engine_name: "Claude Code", model: "", version: "", - agent_version: "2.0.33", + agent_version: "2.0.35", workflow_name: "Documentation Unbloat", experimental: false, supports_tools_allowlist: true, @@ -5316,7 +5316,7 @@ jobs: with: node-version: '24' - name: Install Claude Code CLI - run: npm install -g @anthropic-ai/claude-code@2.0.33 + run: npm install -g @anthropic-ai/claude-code@2.0.35 - name: Execute Claude Code CLI id: agentic_execution # Allowed tools (sorted): diff --git a/pkg/parser/schemas/main_workflow_schema.json b/pkg/parser/schemas/main_workflow_schema.json index 9842923b54f..f6633eea75c 100644 --- a/pkg/parser/schemas/main_workflow_schema.json +++ b/pkg/parser/schemas/main_workflow_schema.json @@ -1102,10 +1102,92 @@ }, "steps": { "type": "array", - "description": "Job steps", + "description": "A job contains a sequence of tasks called steps. Steps can run commands, run setup tasks, or run an action in your repository, a public repository, or an action published in a Docker registry.", "items": { "type": "object", - "additionalProperties": false + "additionalProperties": false, + "oneOf": [ + { + "required": ["uses"] + }, + { + "required": ["run"] + } + ], + "properties": { + "id": { + "type": "string", + "description": "A unique identifier for the step. You can use the id to reference the step in contexts." + }, + "if": { + "description": "You can use the if conditional to prevent a step from running unless a condition is met. You can use any supported context and expression to create a conditional.", + "oneOf": [ + { + "type": "boolean" + }, + { + "type": "number" + }, + { + "type": "string" + } + ] + }, + "name": { + "type": "string", + "description": "A name for your step to display on GitHub." + }, + "uses": { + "type": "string", + "description": "Selects an action to run as part of a step in your job. An action is a reusable unit of code." + }, + "run": { + "type": "string", + "description": "Runs command-line programs using the operating system's shell." + }, + "working-directory": { + "type": "string", + "description": "Working directory where to run the command." + }, + "shell": { + "type": "string", + "description": "Shell to use for running the command." + }, + "with": { + "type": "object", + "description": "A map of the input parameters defined by the action. Each input parameter is a key/value pair.", + "additionalProperties": true + }, + "env": { + "type": "object", + "description": "Sets environment variables for steps to use in the virtual environment.", + "additionalProperties": { + "type": "string" + } + }, + "continue-on-error": { + "description": "Prevents a job from failing when a step fails. Set to true to allow a job to pass when this step fails.", + "oneOf": [ + { + "type": "boolean" + }, + { + "type": "string" + } + ] + }, + "timeout-minutes": { + "description": "The maximum number of minutes to run the step before killing the process.", + "oneOf": [ + { + "type": "number" + }, + { + "type": "string" + } + ] + } + } } }, "if": { diff --git a/pkg/workflow/compiler_jobs.go b/pkg/workflow/compiler_jobs.go index fc1286d08d9..0418abd270e 100644 --- a/pkg/workflow/compiler_jobs.go +++ b/pkg/workflow/compiler_jobs.go @@ -662,6 +662,14 @@ func (c *Compiler) buildMainJob(data *WorkflowData, activationJobCreated bool) ( depends = []string{constants.ActivationJobName} // Depend on the activation job only if it exists } + // Add custom jobs as dependencies if they exist + // This allows the agent job to wait for custom jobs to complete before running + if data.Jobs != nil { + for jobName := range data.Jobs { + depends = append(depends, jobName) + } + } + // Build outputs for all engines (GH_AW_SAFE_OUTPUTS functionality) // Only include output if the workflow actually uses the safe-outputs feature var outputs map[string]string diff --git a/pkg/workflow/jobs_full_spec_test.go b/pkg/workflow/jobs_full_spec_test.go new file mode 100644 index 00000000000..13d401f7b5c --- /dev/null +++ b/pkg/workflow/jobs_full_spec_test.go @@ -0,0 +1,305 @@ +package workflow + +import ( + "os" + "path/filepath" + "strings" + "testing" +) + +func TestCustomJobsWithFullStepSpecification(t *testing.T) { + tests := []struct { + name string + frontmatter string + expectedYAML []string // Strings that should be present in the compiled workflow + shouldError bool + }{ + { + name: "job with full step properties", + frontmatter: `--- +on: workflow_dispatch +permissions: + contents: read +jobs: + test-job: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 1 + persist-credentials: false + - name: Run command + id: run-cmd + run: echo "test" + env: + NODE_ENV: test + timeout-minutes: 5 + continue-on-error: false + shell: bash + working-directory: ./src + - name: Conditional step + if: github.ref == 'refs/heads/main' + run: echo "main only" +--- + +# Test workflow +`, + expectedYAML: []string{ + "test-job:", + "runs-on: ubuntu-latest", + "- name: Checkout", + "uses: actions/checkout@", + "with:", + "fetch-depth: 1", + "persist-credentials: false", + "- name: Run command", + "id: run-cmd", + "run: echo \"test\"", + "env:", + "NODE_ENV: test", + "timeout-minutes: 5", + "continue-on-error: false", + "shell: bash", + "working-directory: ./src", + "- name: Conditional step", + "if: github.ref == 'refs/heads/main'", + }, + shouldError: false, + }, + { + name: "job with uses action step", + frontmatter: `--- +on: push +permissions: + contents: read +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/setup-node@v4 + with: + node-version: '20' + cache: 'npm' +--- + +# Build workflow +`, + expectedYAML: []string{ + "build:", + "- uses: actions/setup-node@", + "with:", + "node-version:", // Both "20" and '20' are valid YAML + "cache:", // Both "npm" and 'npm' are valid YAML + }, + shouldError: false, + }, + { + name: "job with run step", + frontmatter: `--- +on: push +permissions: + contents: read +jobs: + test: + runs-on: ubuntu-latest + steps: + - run: npm test +--- + +# Test workflow +`, + expectedYAML: []string{ + "test:", + "- run: npm test", + }, + shouldError: false, + }, + { + name: "job with if condition on step", + frontmatter: `--- +on: pull_request +permissions: + contents: read +jobs: + conditional: + runs-on: ubuntu-latest + steps: + - name: Always run + run: echo "always" + - name: Conditional + if: github.event_name == 'pull_request' + run: echo "PR only" +--- + +# Conditional workflow +`, + expectedYAML: []string{ + "conditional:", + "- name: Always run", + "run: echo \"always\"", + "- name: Conditional", + "if: github.event_name == 'pull_request'", + "run: echo \"PR only\"", + }, + shouldError: false, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + // Create a temporary workflow file + tmpDir := t.TempDir() + testFile := filepath.Join(tmpDir, "test-workflow.md") + err := os.WriteFile(testFile, []byte(tt.frontmatter), 0644) + if err != nil { + t.Fatalf("Failed to create test file: %v", err) + } + + // Compile the workflow + compiler := NewCompiler(false, "", "test") + err = compiler.CompileWorkflow(testFile) + + if tt.shouldError { + if err == nil { + t.Errorf("Expected error but got none") + } + return + } + + if err != nil { + t.Fatalf("Unexpected compilation error: %v", err) + } + + // Read the generated lock file + lockFile := strings.TrimSuffix(testFile, ".md") + ".lock.yml" + yamlBytes, err := os.ReadFile(lockFile) + if err != nil { + t.Fatalf("Failed to read lock file: %v", err) + } + yamlContent := string(yamlBytes) + + // Check for expected strings in the YAML + for _, expected := range tt.expectedYAML { + if !strings.Contains(yamlContent, expected) { + t.Errorf("Expected YAML to contain %q\nGot:\n%s", expected, yamlContent) + } + } + }) + } +} + +func TestStepValidation(t *testing.T) { + tests := []struct { + name string + frontmatter string + shouldError bool + errorMsg string + }{ + { + name: "step without uses or run should be invalid", + frontmatter: `--- +on: push +permissions: + contents: read +jobs: + invalid: + runs-on: ubuntu-latest + steps: + - name: Invalid step + id: test +--- + +# Invalid workflow +`, + // Schema validation correctly rejects steps without 'uses' or 'run' + shouldError: true, + errorMsg: "oneOf", + }, + { + name: "step with both uses and run should be invalid", + frontmatter: `--- +on: push +permissions: + contents: read +jobs: + invalid: + runs-on: ubuntu-latest + steps: + - name: Invalid step + uses: actions/checkout@v4 + run: echo "test" +--- + +# Invalid workflow +`, + // Schema validation correctly rejects steps with both 'uses' AND 'run' + shouldError: true, + errorMsg: "oneOf", + }, + { + name: "step with only uses is valid", + frontmatter: `--- +on: push +permissions: + contents: read +jobs: + valid: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 +--- + +# Valid workflow +`, + shouldError: false, + }, + { + name: "step with only run is valid", + frontmatter: `--- +on: push +permissions: + contents: read +jobs: + valid: + runs-on: ubuntu-latest + steps: + - run: echo "test" +--- + +# Valid workflow +`, + shouldError: false, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + // Create a temporary workflow file + tmpDir := t.TempDir() + testFile := filepath.Join(tmpDir, "test-workflow.md") + err := os.WriteFile(testFile, []byte(tt.frontmatter), 0644) + if err != nil { + t.Fatalf("Failed to create test file: %v", err) + } + + // Compile the workflow + compiler := NewCompiler(false, "", "test") + err = compiler.CompileWorkflow(testFile) + + if tt.shouldError { + if err == nil { + t.Errorf("Expected error but got none") + return + } + if tt.errorMsg != "" && !strings.Contains(err.Error(), tt.errorMsg) { + t.Errorf("Expected error containing %q, got: %v", tt.errorMsg, err) + } + } else { + if err != nil { + t.Errorf("Unexpected error: %v", err) + } + } + }) + } +}