explainthisrepo 0.1.5 → 0.1.7
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/cli.js +5 -4
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -4,20 +4,23 @@ import process from "node:process";
|
|
|
4
4
|
import { readFileSync } from "node:fs";
|
|
5
5
|
import path from "node:path";
|
|
6
6
|
import { fileURLToPath } from "node:url";
|
|
7
|
-
import { fetchRepo, fetchReadme } from "./github.js";
|
|
7
|
+
import { fetchRepo, fetchReadme, fetchLanguages } from "./github.js";
|
|
8
8
|
import { buildPrompt, buildSimplePrompt } from "./prompt.js";
|
|
9
9
|
import { generateExplanation } from "./generate.js";
|
|
10
10
|
import { writeOutput } from "./writer.js";
|
|
11
11
|
import { readRepoSignalFiles } from "./repo_reader.js";
|
|
12
|
-
import { fetchLanguages } from "./github.js";
|
|
13
12
|
import { detectStack } from "./stack-detector.js";
|
|
14
13
|
import { printStack } from "./stack_printer.js";
|
|
15
14
|
function usage() {
|
|
15
|
+
const version = getPkgVersion();
|
|
16
|
+
console.log(`ExplainThisRepo v${version}`);
|
|
17
|
+
console.log("Explain GitHub repositories in plain English.\n");
|
|
16
18
|
console.log("usage:");
|
|
17
19
|
console.log(" explainthisrepo owner/repo");
|
|
18
20
|
console.log(" explainthisrepo owner/repo --detailed");
|
|
19
21
|
console.log(" explainthisrepo owner/repo --quick");
|
|
20
22
|
console.log(" explainthisrepo owner/repo --simple");
|
|
23
|
+
console.log(" explainthisrepo owner/repo --stack");
|
|
21
24
|
console.log(" explainthisrepo --doctor");
|
|
22
25
|
console.log(" explainthisrepo --version");
|
|
23
26
|
}
|
|
@@ -101,8 +104,6 @@ async function main() {
|
|
|
101
104
|
quick = true;
|
|
102
105
|
else if (args[1] === "--simple")
|
|
103
106
|
simple = true;
|
|
104
|
-
else if (args[1] === "--stack")
|
|
105
|
-
stack = true;
|
|
106
107
|
else {
|
|
107
108
|
usage();
|
|
108
109
|
process.exit(1);
|