@sdods/cli 0.13.0 → 0.13.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/dist/.tsbuildinfo +1 -1
- package/dist/commands/feedback.d.ts +3 -2
- package/dist/commands/feedback.js +23 -37
- package/package.json +11 -11
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import type { Command } from 'commander';
|
|
2
2
|
/**
|
|
3
|
-
* `sdods feedback` — open
|
|
4
|
-
*
|
|
3
|
+
* `sdods feedback` — open the sdods.com feedback form (feature request or bug report).
|
|
4
|
+
* It prints the title, message and, for bug reports, the version, OS and doctor summary, for the
|
|
5
|
+
* user to paste into the form.
|
|
5
6
|
*/
|
|
6
7
|
export declare function register(program: Command): void;
|
|
7
8
|
//# sourceMappingURL=feedback.d.ts.map
|
|
@@ -2,58 +2,44 @@ import { execa } from 'execa';
|
|
|
2
2
|
import pc from 'picocolors';
|
|
3
3
|
import { VERSION } from '@sdods/core';
|
|
4
4
|
import { json, out } from '../ui.js';
|
|
5
|
-
const REPO = 'https://github.com/YarlisAISolutions/SDODS';
|
|
6
|
-
const DISCUSSIONS = `${REPO}/discussions/categories/ideas`;
|
|
7
5
|
/**
|
|
8
|
-
*
|
|
9
|
-
*
|
|
6
|
+
* The source repository is private, so prefilled GitHub issue forms would 404 for users.
|
|
7
|
+
* Feedback goes through sdods.com, which takes feature requests, bug reports and notes directly.
|
|
8
|
+
*/
|
|
9
|
+
const FEEDBACK = 'https://sdods.com/feedback/#write';
|
|
10
|
+
const QUESTIONS = 'https://sdods.com/questions/';
|
|
11
|
+
/**
|
|
12
|
+
* `sdods feedback` — open the sdods.com feedback form (feature request or bug report).
|
|
13
|
+
* It prints the title, message and, for bug reports, the version, OS and doctor summary, for the
|
|
14
|
+
* user to paste into the form.
|
|
10
15
|
*/
|
|
11
16
|
export function register(program) {
|
|
12
17
|
program
|
|
13
18
|
.command('feedback')
|
|
14
|
-
.description('Request a feature or report a bug (
|
|
19
|
+
.description('Request a feature or report a bug (opens the sdods.com feedback form)')
|
|
15
20
|
.option('--feature', 'feature request (default)')
|
|
16
21
|
.option('--bug', 'bug report with environment details from `sdods doctor`')
|
|
17
|
-
.option('--discuss', 'print the
|
|
18
|
-
.option('-t, --title <text>', '
|
|
19
|
-
.option('-m, --message <text>', 'problem statement or observed behaviour')
|
|
22
|
+
.option('--discuss', 'print the questions page URL instead')
|
|
23
|
+
.option('-t, --title <text>', 'title, printed for you to paste into the form')
|
|
24
|
+
.option('-m, --message <text>', 'problem statement or observed behaviour, printed with the title')
|
|
20
25
|
.option('--open', 'open the URL in the default browser')
|
|
21
26
|
.action(async (opts, cmd) => {
|
|
22
27
|
const root = cmd.parent ?? cmd;
|
|
23
28
|
const asJson = Boolean(root.opts().json);
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
}
|
|
28
|
-
else if (opts.bug) {
|
|
29
|
-
const params = new URLSearchParams({
|
|
30
|
-
template: 'bug_report.yml',
|
|
31
|
-
title: opts.title ? `[Bug] ${opts.title}` : '[Bug] ',
|
|
32
|
-
labels: 'bug,triage',
|
|
33
|
-
'sdods-version': VERSION,
|
|
34
|
-
os: osLabel(),
|
|
35
|
-
});
|
|
29
|
+
const url = opts.discuss ? QUESTIONS : FEEDBACK;
|
|
30
|
+
const lines = [opts.title && `Title: ${opts.title}`, opts.message];
|
|
31
|
+
if (opts.bug && !opts.discuss) {
|
|
36
32
|
const doctor = await doctorSummary();
|
|
37
|
-
|
|
38
|
-
params.set('doctor', doctor);
|
|
39
|
-
if (opts.message)
|
|
40
|
-
params.set('actual', opts.message);
|
|
41
|
-
url = `${REPO}/issues/new?${params.toString()}`;
|
|
42
|
-
}
|
|
43
|
-
else {
|
|
44
|
-
const params = new URLSearchParams({
|
|
45
|
-
template: 'feature_request.yml',
|
|
46
|
-
title: opts.title ? `[Feature] ${opts.title}` : '[Feature] ',
|
|
47
|
-
labels: 'enhancement,triage',
|
|
48
|
-
'sdods-version': VERSION,
|
|
49
|
-
});
|
|
50
|
-
if (opts.message)
|
|
51
|
-
params.set('problem', opts.message);
|
|
52
|
-
url = `${REPO}/issues/new?${params.toString()}`;
|
|
33
|
+
lines.push(`sdods ${VERSION}`, `OS: ${osLabel()}`, doctor && `doctor: ${doctor}`);
|
|
53
34
|
}
|
|
35
|
+
const details = opts.discuss ? undefined : lines.filter(Boolean).join('\n') || undefined;
|
|
54
36
|
if (asJson)
|
|
55
|
-
return json({ url });
|
|
37
|
+
return json(details ? { url, details } : { url });
|
|
56
38
|
out(url);
|
|
39
|
+
if (details) {
|
|
40
|
+
out(pc.dim('Paste these details into the form:'));
|
|
41
|
+
out(details);
|
|
42
|
+
}
|
|
57
43
|
if (opts.open) {
|
|
58
44
|
const opener = process.platform === 'darwin'
|
|
59
45
|
? 'open'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sdods/cli",
|
|
3
|
-
"version": "0.13.
|
|
3
|
+
"version": "0.13.2",
|
|
4
4
|
"description": "SDODS command line: run, record, analyze, agents, MCP server, scheduler and the web server.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"funding": "https://sdods.com/sponsor/",
|
|
@@ -26,26 +26,26 @@
|
|
|
26
26
|
"node": ">=22"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@sdods/contracts": "0.13.
|
|
30
|
-
"@sdods/core": "0.13.
|
|
29
|
+
"@sdods/contracts": "0.13.2",
|
|
30
|
+
"@sdods/core": "0.13.2",
|
|
31
31
|
"commander": "^15.0.0",
|
|
32
32
|
"execa": "^10.1.0",
|
|
33
33
|
"picocolors": "^1.1.1",
|
|
34
34
|
"semver": "^7.8.5",
|
|
35
35
|
"yaml": "^2.9.1",
|
|
36
36
|
"zod": "^4.6.5",
|
|
37
|
-
"@playwright/test": "^1.
|
|
38
|
-
"playwright-core": "^1.
|
|
39
|
-
"@sdods/integrations": "0.13.
|
|
40
|
-
"@sdods/mcp": "0.13.
|
|
41
|
-
"@sdods/agents": "0.13.
|
|
42
|
-
"@sdods/db": "0.13.
|
|
37
|
+
"@playwright/test": "^1.64.0",
|
|
38
|
+
"playwright-core": "^1.64.0",
|
|
39
|
+
"@sdods/integrations": "0.13.2",
|
|
40
|
+
"@sdods/mcp": "0.13.2",
|
|
41
|
+
"@sdods/agents": "0.13.2",
|
|
42
|
+
"@sdods/db": "0.13.2",
|
|
43
43
|
"csv-parse": "^7.0.3",
|
|
44
|
-
"@sdods/server": "0.13.
|
|
44
|
+
"@sdods/server": "0.13.2"
|
|
45
45
|
},
|
|
46
46
|
"homepage": "https://sdods.com",
|
|
47
47
|
"bugs": {
|
|
48
|
-
"url": "https://
|
|
48
|
+
"url": "https://sdods.com/feedback/"
|
|
49
49
|
},
|
|
50
50
|
"repository": {
|
|
51
51
|
"type": "git",
|