truecourse 0.4.1 → 0.4.2
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/cli.mjs +1 -1
- package/package.json +1 -1
- package/postinstall.cjs +12 -16
package/cli.mjs
CHANGED
|
@@ -130437,7 +130437,7 @@ async function runHooksRun() {
|
|
|
130437
130437
|
|
|
130438
130438
|
// tools/cli/src/index.ts
|
|
130439
130439
|
var program2 = new Command();
|
|
130440
|
-
program2.name("truecourse").version("0.4.
|
|
130440
|
+
program2.name("truecourse").version("0.4.2").description("TrueCourse CLI \u2014 analyze your repository and open the dashboard");
|
|
130441
130441
|
var dashboardCmd = program2.command("dashboard").description("Start the TrueCourse dashboard and open it in your browser").action(async () => {
|
|
130442
130442
|
await runDashboard();
|
|
130443
130443
|
});
|
package/package.json
CHANGED
package/postinstall.cjs
CHANGED
|
@@ -42,30 +42,26 @@ try {
|
|
|
42
42
|
|
|
43
43
|
const { execSync } = require('child_process');
|
|
44
44
|
|
|
45
|
-
//
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
.join(' ');
|
|
53
|
-
} catch {
|
|
54
|
-
packages = 'tree-sitter tree-sitter-typescript tree-sitter-javascript tree-sitter-python';
|
|
55
|
-
}
|
|
45
|
+
// The optional-dep install already extracted tree-sitter's source into
|
|
46
|
+
// node_modules/tree-sitter/ — only its native .node binary failed to build
|
|
47
|
+
// (Node 24 needs C++20, default is C++17). `npm rebuild` runs the build
|
|
48
|
+
// scripts on the existing install with our CXXFLAGS, leaving manifests
|
|
49
|
+
// untouched so the install survives later `npm exec` integrity passes
|
|
50
|
+
// that would prune an `npm install --no-save` addition as extraneous.
|
|
51
|
+
const packages = ['tree-sitter', 'tree-sitter-typescript', 'tree-sitter-javascript', 'tree-sitter-python'];
|
|
56
52
|
|
|
57
|
-
log('
|
|
53
|
+
log('Rebuilding tree-sitter with CXXFLAGS="-std=c++20"...');
|
|
58
54
|
|
|
59
55
|
try {
|
|
60
|
-
execSync(`npm
|
|
56
|
+
execSync(`npm rebuild ${packages.join(' ')}`, {
|
|
61
57
|
stdio: 'inherit',
|
|
62
58
|
env: { ...process.env, CXXFLAGS: '-std=c++20' },
|
|
63
59
|
});
|
|
64
|
-
log('tree-sitter:
|
|
60
|
+
log('tree-sitter: rebuilt OK');
|
|
65
61
|
} catch {
|
|
66
|
-
log('tree-sitter:
|
|
62
|
+
log('tree-sitter: rebuild failed');
|
|
67
63
|
console.warn(
|
|
68
|
-
'\n[TrueCourse] Could not
|
|
64
|
+
'\n[TrueCourse] Could not rebuild tree-sitter automatically.\n' +
|
|
69
65
|
'Fix: set the C++20 flag manually and reinstall:\n' +
|
|
70
66
|
' export CXXFLAGS="-std=c++20"\n' +
|
|
71
67
|
' npx truecourse\n\n' +
|