@nhonh/qabot 0.2.0 → 0.2.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nhonh/qabot",
3
- "version": "0.2.0",
3
+ "version": "0.2.1",
4
4
  "description": "AI-powered universal QA automation tool. Import any project, AI analyzes and runs tests across all layers.",
5
5
  "main": "src/index.js",
6
6
  "bin": {
@@ -232,17 +232,17 @@ async function interactiveSetup(projectDir, config, isEmpty) {
232
232
  if (isEmpty) {
233
233
  logger.blank();
234
234
  logger.warn(
235
- "No qabot.config.js found. Run `qabot init` first, then `qabot auth`.",
235
+ "No qabot.config.json found. Run `qabot init` first, then `qabot auth`.",
236
236
  );
237
237
  logger.blank();
238
- logger.info("Or manually add to qabot.config.js:");
238
+ logger.info("Or manually add to qabot.config.json:");
239
239
  logger.dim(` ai: ${JSON.stringify(aiConfig, null, 4)}`);
240
240
  return;
241
241
  }
242
242
 
243
243
  await writeConfig(projectDir, config);
244
244
  logger.blank();
245
- logger.success("AI configuration saved to qabot.config.js");
245
+ logger.success("AI configuration saved to qabot.config.json");
246
246
  logger.blank();
247
247
  logger.info("Test your setup:");
248
248
  logger.dim(" qabot auth --test");
@@ -24,7 +24,7 @@ async function runGenerate(feature, options) {
24
24
  const { config, isEmpty } = await loadConfig(projectDir);
25
25
 
26
26
  if (isEmpty) {
27
- logger.warn("No qabot.config.js found. Run `qabot init` first.");
27
+ logger.warn("No qabot.config.json found. Run `qabot init` first.");
28
28
  return;
29
29
  }
30
30
 
@@ -59,7 +59,7 @@ async function runInit(options) {
59
59
  const { proceed } = await enquirer.prompt({
60
60
  type: "confirm",
61
61
  name: "proceed",
62
- message: "Generate qabot.config.js with these settings?",
62
+ message: "Generate qabot.config.json with these settings?",
63
63
  initial: true,
64
64
  });
65
65
  if (!proceed) {
@@ -31,7 +31,7 @@ async function runTests(feature, options) {
31
31
  const { config, isEmpty } = await loadConfig(projectDir);
32
32
 
33
33
  if (isEmpty) {
34
- logger.warn("No qabot.config.js found. Run `qabot init` first.");
34
+ logger.warn("No qabot.config.json found. Run `qabot init` first.");
35
35
  logger.dim("Or run tests with: qabot init -y && qabot run");
36
36
  return;
37
37
  }
@@ -5,11 +5,12 @@ import { DEFAULT_CONFIG, TOOL_NAME } from "./constants.js";
5
5
 
6
6
  const explorer = cosmiconfig(TOOL_NAME, {
7
7
  searchPlaces: [
8
- "qabot.config.js",
8
+ "qabot.config.json",
9
+ ".qabotrc.json",
10
+ ".qabotrc",
9
11
  "qabot.config.mjs",
12
+ "qabot.config.js",
10
13
  "qabot.config.cjs",
11
- ".qabotrc.json",
12
- ".qabotrc.js",
13
14
  "package.json",
14
15
  ],
15
16
  });
@@ -33,11 +34,12 @@ export async function loadConfig(projectDir) {
33
34
  }
34
35
 
35
36
  export async function writeConfig(projectDir, configData) {
36
- const configPath = path.join(projectDir, "qabot.config.js");
37
- const lines = [
38
- "export default " + JSON.stringify(configData, null, 2) + ";\n",
39
- ];
40
- await writeFile(configPath, lines.join(""), "utf-8");
37
+ const configPath = path.join(projectDir, "qabot.config.json");
38
+ await writeFile(
39
+ configPath,
40
+ JSON.stringify(configData, null, 2) + "\n",
41
+ "utf-8",
42
+ );
41
43
  return configPath;
42
44
  }
43
45
 
@@ -1,4 +1,4 @@
1
- export const VERSION = "0.2.0";
1
+ export const VERSION = "0.2.1";
2
2
  export const TOOL_NAME = "qabot";
3
3
 
4
4
  export const PROJECT_TYPES = [