@_mustachio/ai-review-agent 1.0.2 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/action.yml CHANGED
@@ -38,9 +38,9 @@ inputs:
38
38
  required: false
39
39
  default: ''
40
40
  opencode-version:
41
- description: 'Pinned version of opencode-ai to install (default: 0.2.21)'
41
+ description: 'Pinned version of opencode-ai to install (default: 1.3.2)'
42
42
  required: false
43
- default: '0.2.21'
43
+ default: '1.3.2'
44
44
 
45
45
  outputs:
46
46
  approved:
package/dist/index.js CHANGED
@@ -25675,7 +25675,7 @@ const DEFAULT_EXCLUDES = [
25675
25675
  '**/*.snap',
25676
25676
  ];
25677
25677
 
25678
- const DEFAULT_OPENCODE_VERSION = '0.2.21';
25678
+ const DEFAULT_OPENCODE_VERSION = '1.3.2';
25679
25679
 
25680
25680
  /**
25681
25681
  * Run the full review pipeline. Platform-agnostic.
@@ -26104,10 +26104,7 @@ module.exports = { loadPrompt, renderPrompt };
26104
26104
  /***/ 8161:
26105
26105
  /***/ ((module, __unused_webpack_exports, __nccwpck_require__) => {
26106
26106
 
26107
- const fs = __nccwpck_require__(9896);
26108
- const path = __nccwpck_require__(6928);
26109
- const os = __nccwpck_require__(857);
26110
- const { execSync } = __nccwpck_require__(5317);
26107
+ const { execFileSync } = __nccwpck_require__(5317);
26111
26108
 
26112
26109
  const DEFAULT_REVIEW = {
26113
26110
  approve: false,
@@ -26121,16 +26118,14 @@ const DEFAULT_REVIEW = {
26121
26118
  * Writes prompt to a temp file and pipes via stdin to avoid CLI arg size limits.
26122
26119
  */
26123
26120
  function runReview(prompt, id, { log = console.log } = {}) {
26124
- const tmpFile = path.join(os.tmpdir(), `ai-review-prompt-${id}.txt`);
26125
- fs.writeFileSync(tmpFile, prompt, 'utf-8');
26126
-
26127
26121
  try {
26128
26122
  let stderr = '';
26129
26123
  let stdout;
26130
26124
  try {
26131
- stdout = execSync(
26132
- `opencode run --format json --title "PR Review #${id}" "$(cat "${tmpFile}")"`,
26133
- { encoding: 'utf-8', maxBuffer: 50 * 1024 * 1024, stdio: ['pipe', 'pipe', 'pipe'], shell: '/bin/bash' }
26125
+ stdout = execFileSync(
26126
+ 'opencode',
26127
+ ['run', '--format', 'json', prompt],
26128
+ { encoding: 'utf-8', maxBuffer: 50 * 1024 * 1024, stdio: ['pipe', 'pipe', 'pipe'] }
26134
26129
  );
26135
26130
  } catch (execErr) {
26136
26131
  stderr = execErr.stderr || '';
@@ -26144,9 +26139,7 @@ function runReview(prompt, id, { log = console.log } = {}) {
26144
26139
 
26145
26140
  log(`OpenCode stdout (first 500 chars): ${stdout.slice(0, 500)}`);
26146
26141
  return parseReviewOutput(stdout, { log });
26147
- } finally {
26148
- try { fs.unlinkSync(tmpFile); } catch {}
26149
- }
26142
+ } finally {}
26150
26143
  }
26151
26144
 
26152
26145
  /**