mirror of
https://github.com/coleam00/Archon.git
synced 2025-12-24 02:39:17 -05:00
Fix exec declaration error in Stage 2 workflow
- Replace async exec with execSync to avoid declaration issues - Add proper error handling for artifact extraction - Use childProcess module directly instead of destructuring
This commit is contained in:
17
.github/workflows/claude-review-ext.yml
vendored
17
.github/workflows/claude-review-ext.yml
vendored
@@ -63,14 +63,15 @@ jobs:
|
||||
const fs = require('fs');
|
||||
fs.writeFileSync('pr-info.zip', Buffer.from(download.data));
|
||||
|
||||
// Extract the artifact
|
||||
const { exec } = require('child_process');
|
||||
await new Promise((resolve, reject) => {
|
||||
exec('unzip -o pr-info.zip', (error, stdout, stderr) => {
|
||||
if (error) reject(error);
|
||||
else resolve(stdout);
|
||||
});
|
||||
});
|
||||
// Extract the artifact using execSync instead of exec to avoid declaration issues
|
||||
const childProcess = require('child_process');
|
||||
try {
|
||||
childProcess.execSync('unzip -o pr-info.zip');
|
||||
console.log('Artifact extracted successfully');
|
||||
} catch (error) {
|
||||
core.setFailed(`Failed to extract artifact: ${error.message}`);
|
||||
return;
|
||||
}
|
||||
|
||||
// Read and parse PR info
|
||||
const prInfo = JSON.parse(fs.readFileSync('pr-info.json', 'utf8'));
|
||||
|
||||
Reference in New Issue
Block a user