browser-extension-manager 1.2.9 → 1.2.10
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/dist/gulp/tasks/translate.js +16 -0
- package/package.json +1 -1
|
@@ -31,6 +31,16 @@ const LANGUAGES = [
|
|
|
31
31
|
const localesDir = path.join(process.cwd(), 'src', '_locales');
|
|
32
32
|
const enMessagesPath = path.join(localesDir, 'en', 'messages.json');
|
|
33
33
|
|
|
34
|
+
// Check if Claude CLI is installed
|
|
35
|
+
async function isClaudeInstalled() {
|
|
36
|
+
try {
|
|
37
|
+
await execute('which claude');
|
|
38
|
+
return true;
|
|
39
|
+
} catch (e) {
|
|
40
|
+
return false;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
34
44
|
// Main translate task
|
|
35
45
|
async function translate(complete) {
|
|
36
46
|
// Only run in build mode
|
|
@@ -39,6 +49,12 @@ async function translate(complete) {
|
|
|
39
49
|
return complete();
|
|
40
50
|
}
|
|
41
51
|
|
|
52
|
+
// Check if Claude CLI is installed
|
|
53
|
+
if (!await isClaudeInstalled()) {
|
|
54
|
+
logger.log('Skipping translation (Claude CLI not installed)');
|
|
55
|
+
return complete();
|
|
56
|
+
}
|
|
57
|
+
|
|
42
58
|
// Log
|
|
43
59
|
logger.log('Starting translation...');
|
|
44
60
|
|