opendraft 1.5.0 → 1.6.0
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/bin/opendraft.js +25 -7
- package/package.json +1 -1
package/bin/opendraft.js
CHANGED
|
@@ -48,7 +48,7 @@ ${PURPLE}${BOLD} ╔═══════════════════
|
|
|
48
48
|
}
|
|
49
49
|
|
|
50
50
|
function checkPython() {
|
|
51
|
-
// Check various Python commands including versioned ones from Homebrew
|
|
51
|
+
// Check various Python commands including versioned ones from Homebrew and python.org installers
|
|
52
52
|
const pythonCommands = [
|
|
53
53
|
'python3',
|
|
54
54
|
'python',
|
|
@@ -57,10 +57,17 @@ function checkPython() {
|
|
|
57
57
|
'python3.11',
|
|
58
58
|
'python3.10',
|
|
59
59
|
'python3.9',
|
|
60
|
+
// Homebrew
|
|
60
61
|
'/opt/homebrew/bin/python3',
|
|
61
|
-
'/opt/homebrew/bin/python3.
|
|
62
|
+
'/opt/homebrew/bin/python3.13',
|
|
62
63
|
'/opt/homebrew/bin/python3.12',
|
|
64
|
+
'/opt/homebrew/bin/python3.11',
|
|
63
65
|
'/usr/local/bin/python3',
|
|
66
|
+
// python.org macOS installer
|
|
67
|
+
'/Library/Frameworks/Python.framework/Versions/3.13/bin/python3',
|
|
68
|
+
'/Library/Frameworks/Python.framework/Versions/3.12/bin/python3',
|
|
69
|
+
'/Library/Frameworks/Python.framework/Versions/3.11/bin/python3',
|
|
70
|
+
'/Library/Frameworks/Python.framework/Versions/3.10/bin/python3',
|
|
64
71
|
];
|
|
65
72
|
|
|
66
73
|
for (const cmd of pythonCommands) {
|
|
@@ -237,16 +244,27 @@ async function main() {
|
|
|
237
244
|
if (args.includes('--help') || args.includes('-h')) {
|
|
238
245
|
printLogo();
|
|
239
246
|
print(`${BOLD}Usage:${RESET}`);
|
|
240
|
-
print(` ${CYAN}npx opendraft${RESET} Interactive mode`);
|
|
247
|
+
print(` ${CYAN}npx opendraft${RESET} Interactive mode (recommended)`);
|
|
241
248
|
print(` ${CYAN}npx opendraft "Your Topic"${RESET} Quick generate`);
|
|
242
249
|
print(` ${CYAN}npx opendraft --install${RESET} Install/update`);
|
|
243
250
|
console.log();
|
|
244
251
|
print(`${BOLD}Options:${RESET}`);
|
|
245
|
-
print(` --level, -l
|
|
246
|
-
print(` --style, -s
|
|
247
|
-
print(` --
|
|
252
|
+
print(` --level, -l Academic level (research_paper, bachelor, master, phd)`);
|
|
253
|
+
print(` --style, -s Citation style (apa, mla, chicago, ieee)`);
|
|
254
|
+
print(` --lang Language (en, de, es, fr, it, pt, zh, ja, ko, ru)`);
|
|
255
|
+
print(` --output, -o Output directory`);
|
|
256
|
+
console.log();
|
|
257
|
+
print(`${BOLD}Cover Page (optional):${RESET}`);
|
|
258
|
+
print(` --author Your name`);
|
|
259
|
+
print(` --institution University/institution`);
|
|
260
|
+
print(` --department Department name`);
|
|
261
|
+
print(` --advisor Supervisor name`);
|
|
262
|
+
console.log();
|
|
263
|
+
print(`${BOLD}Examples:${RESET}`);
|
|
264
|
+
print(` ${CYAN}npx opendraft "AI in Healthcare" --level master${RESET}`);
|
|
265
|
+
print(` ${CYAN}npx opendraft "Climate Change" --lang de --author "Max Müller"${RESET}`);
|
|
248
266
|
console.log();
|
|
249
|
-
print(`${GRAY}
|
|
267
|
+
print(`${GRAY}https://opendraft.xyz/docs${RESET}`);
|
|
250
268
|
console.log();
|
|
251
269
|
return;
|
|
252
270
|
}
|