productkit 1.4.0 → 1.5.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/README.md CHANGED
@@ -97,6 +97,7 @@ These markdown files are your product foundation — share them with your team,
97
97
  | `productkit init --existing` | Add Product Kit to the current directory |
98
98
  | `productkit status` | Show progress — which artifacts exist and what's next |
99
99
  | `productkit update` | Refresh slash commands to the latest version |
100
+ | `productkit reset` | Remove all artifacts and start over |
100
101
  | `productkit check` | Verify Claude Code is installed |
101
102
 
102
103
  ## How It Works
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "productkit",
3
- "version": "1.4.0",
3
+ "version": "1.5.1",
4
4
  "description": "Slash-command-driven product thinking toolkit for Claude Code",
5
5
  "main": "src/cli.js",
6
6
  "bin": {
@@ -20,6 +20,14 @@
20
20
  "slash-commands",
21
21
  "product-thinking"
22
22
  ],
23
+ "repository": {
24
+ "type": "git",
25
+ "url": "https://github.com/iamquechua/product-kit.git"
26
+ },
27
+ "homepage": "https://github.com/iamquechua/product-kit#readme",
28
+ "bugs": {
29
+ "url": "https://github.com/iamquechua/product-kit/issues"
30
+ },
23
31
  "author": "Douno",
24
32
  "license": "MIT",
25
33
  "dependencies": {
package/src/cli.js CHANGED
@@ -6,13 +6,14 @@ const initCommand = require('./commands/init');
6
6
  const checkCommand = require('./commands/check');
7
7
  const statusCommand = require('./commands/status');
8
8
  const updateCommand = require('./commands/update');
9
+ const resetCommand = require('./commands/reset');
9
10
 
10
11
  const program = new Command();
11
12
 
12
13
  program
13
14
  .name('productkit')
14
15
  .description(chalk.cyan.bold('Product thinking toolkit for Claude Code'))
15
- .version('1.4.0');
16
+ .version('1.5.0');
16
17
 
17
18
  program
18
19
  .command('init [projectName]')
@@ -35,6 +36,11 @@ program
35
36
  .description('Refresh slash commands to the latest version')
36
37
  .action(updateCommand);
37
38
 
39
+ program
40
+ .command('reset')
41
+ .description('Remove all artifacts and start over')
42
+ .action(resetCommand);
43
+
38
44
  program.parse(process.argv);
39
45
 
40
46
  if (process.argv.length === 2) {
@@ -0,0 +1,45 @@
1
+ const fs = require('fs-extra');
2
+ const path = require('path');
3
+ const chalk = require('chalk');
4
+
5
+ const ARTIFACTS = [
6
+ 'constitution.md',
7
+ 'users.md',
8
+ 'problem.md',
9
+ 'assumptions.md',
10
+ 'solution.md',
11
+ 'priorities.md',
12
+ 'spec.md',
13
+ ];
14
+
15
+ async function reset() {
16
+ const root = process.cwd();
17
+ const configPath = path.join(root, '.productkit', 'config.json');
18
+
19
+ if (!fs.existsSync(configPath)) {
20
+ console.error(chalk.red('Not a Product Kit project.'));
21
+ console.log('Run: productkit init <name>');
22
+ process.exit(1);
23
+ }
24
+
25
+ let removed = 0;
26
+
27
+ for (const file of ARTIFACTS) {
28
+ const filePath = path.join(root, file);
29
+ if (fs.existsSync(filePath)) {
30
+ fs.removeSync(filePath);
31
+ console.log(chalk.yellow(` removed ${file}`));
32
+ removed++;
33
+ }
34
+ }
35
+
36
+ console.log();
37
+ if (removed > 0) {
38
+ console.log(chalk.green.bold(`Reset complete. ${removed} artifact${removed === 1 ? '' : 's'} removed.`));
39
+ } else {
40
+ console.log(chalk.green.bold('Nothing to reset — no artifacts found.'));
41
+ }
42
+ console.log();
43
+ }
44
+
45
+ module.exports = reset;