@bicorne/task-flow 0.1.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.
Files changed (58) hide show
  1. package/README.md +337 -145
  2. package/SKILL.md +9 -5
  3. package/assets/.harnessrc +0 -1
  4. package/dist/commands/analyze.js +160 -318
  5. package/dist/commands/archive.js +44 -48
  6. package/dist/commands/design.js +225 -400
  7. package/dist/commands/extract.js +174 -303
  8. package/dist/commands/init.js +103 -148
  9. package/dist/commands/merge/index.js +184 -295
  10. package/dist/commands/merge/merger.js +112 -134
  11. package/dist/commands/merge/types.js +3 -5
  12. package/dist/commands/merge/validators.js +115 -132
  13. package/dist/commands/merge.js +46 -13
  14. package/dist/commands/start.js +155 -248
  15. package/dist/commands/status.js +68 -129
  16. package/dist/commands/sync.js +37 -53
  17. package/dist/commands/tasks-gen/doc-parser.js +148 -228
  18. package/dist/commands/tasks-gen/generators.js +104 -116
  19. package/dist/commands/tasks-gen/index.js +206 -314
  20. package/dist/commands/tasks-gen/parsers.js +131 -232
  21. package/dist/commands/tasks-gen/templates.js +9 -10
  22. package/dist/commands/tasks-gen/types.js +36 -14
  23. package/dist/commands/tasks-gen/validators.js +33 -49
  24. package/dist/commands/tasks.js +58 -20
  25. package/dist/commands/worktree.js +167 -249
  26. package/dist/hooks/check-prd-exists.js +45 -55
  27. package/dist/hooks/check-worktree-conflict.js +68 -101
  28. package/dist/hooks/hook-runner/executor.js +134 -126
  29. package/dist/hooks/hook-runner/index.js +181 -196
  30. package/dist/hooks/hook-runner/loader.js +74 -113
  31. package/dist/hooks/hook-runner/types.js +3 -5
  32. package/dist/hooks/hook-runner.js +94 -28
  33. package/dist/hooks/phase-complete-detector.js +125 -191
  34. package/dist/hooks/phase-gate-validator.js +315 -376
  35. package/dist/hooks/save-checkpoint.js +87 -130
  36. package/dist/hooks/start-mcp-servers.js +50 -65
  37. package/dist/hooks/stop-mcp-servers.js +40 -49
  38. package/dist/index.js +84 -153
  39. package/dist/lib/archive.js +126 -209
  40. package/dist/lib/config.d.ts +0 -2
  41. package/dist/lib/config.js +141 -230
  42. package/dist/lib/constants.js +155 -145
  43. package/dist/lib/interactive.js +98 -148
  44. package/dist/lib/mcp-client.js +197 -320
  45. package/dist/lib/state.js +142 -253
  46. package/dist/slash/executor.js +309 -233
  47. package/dist/slash/index.js +69 -43
  48. package/dist/slash/parser.js +84 -97
  49. package/dist/slash/registry.js +100 -88
  50. package/dist/spec/openspec-to-task/builders.js +96 -109
  51. package/dist/spec/openspec-to-task/index.js +112 -173
  52. package/dist/spec/openspec-to-task/parsers.js +148 -219
  53. package/dist/spec/openspec-to-task/types.js +3 -5
  54. package/dist/spec/sync-openspec-to-task.js +47 -19
  55. package/dist/spec/sync-task-to-openspec.js +241 -272
  56. package/dist/types/ai-context.js +3 -8
  57. package/package.json +9 -7
  58. package/references/CLI-TUTORIAL.md +4 -10
@@ -1,275 +1,193 @@
1
- "use strict";
2
- /**
3
- * commands/worktree.ts
4
- * Create isolated git worktree for task execution
5
- */
6
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
- if (k2 === undefined) k2 = k;
8
- var desc = Object.getOwnPropertyDescriptor(m, k);
9
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
- desc = { enumerable: true, get: function() { return m[k]; } };
11
- }
12
- Object.defineProperty(o, k2, desc);
13
- }) : (function(o, m, k, k2) {
14
- if (k2 === undefined) k2 = k;
15
- o[k2] = m[k];
16
- }));
17
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
18
- Object.defineProperty(o, "default", { enumerable: true, value: v });
19
- }) : function(o, v) {
20
- o["default"] = v;
21
- });
22
- var __importStar = (this && this.__importStar) || (function () {
23
- var ownKeys = function(o) {
24
- ownKeys = Object.getOwnPropertyNames || function (o) {
25
- var ar = [];
26
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
27
- return ar;
28
- };
29
- return ownKeys(o);
30
- };
31
- return function (mod) {
32
- if (mod && mod.__esModule) return mod;
33
- var result = {};
34
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
35
- __setModuleDefault(result, mod);
36
- return result;
37
- };
38
- })();
39
- Object.defineProperty(exports, "__esModule", { value: true });
40
- exports.createWorktree = createWorktree;
41
- exports.main = main;
42
- const fs = __importStar(require("fs"));
43
- const path = __importStar(require("path"));
44
- const child_process_1 = require("child_process");
45
- const config_1 = require("../lib/config");
46
- const interactive_1 = require("../lib/interactive");
47
- function parseArgs(argv) {
48
- const args = {};
49
- for (let i = 2; i < argv.length; i += 1) {
50
- const token = argv[i] || '';
51
- if (!token.startsWith('--')) {
52
- continue;
53
- }
54
- const key = token.slice(2);
55
- const next = argv[i + 1] || '';
56
- if (!next || next.startsWith('--')) {
57
- args[key] = true;
58
- continue;
59
- }
60
- args[key] = next;
61
- i += 1;
62
- }
63
- return args;
1
+ function e(r) {
2
+ return "function" != typeof WeakMap ? null : (e = function(e) {
3
+ return new WeakMap();
4
+ })(r);
64
5
  }
65
- function toChangeName(input) {
66
- return String(input || '')
67
- .trim()
68
- .replace(/[^a-zA-Z0-9-_]/g, '-')
69
- .replace(/-+/g, '-')
70
- .replace(/^-|-$/g, '');
71
- }
72
- function getGitBranch(cwd) {
73
- try {
74
- return (0, child_process_1.execSync)('git rev-parse --abbrev-ref HEAD', { cwd, encoding: 'utf8' }).trim();
75
- }
76
- catch {
77
- return 'main';
78
- }
79
- }
80
- /**
81
- * Validate config has required properties for worktree creation
82
- */
83
- function validateConfigForWorktree(config) {
84
- if (!config.projectRoot) {
85
- return {
86
- valid: false,
87
- reason: 'missing-project-root',
88
- message: 'Config missing projectRoot',
89
- };
90
- }
91
- if (!config.worktreesDirAbs) {
92
- return {
93
- valid: false,
94
- reason: 'missing-worktrees-dir',
95
- message: 'Config missing worktreesDirAbs',
96
- };
6
+ function r(r, s) {
7
+ var t, n, o;
8
+ if (!s && r && r.__esModule) return r;
9
+ if (null === r || "object" != typeof r && "function" != typeof r) return {
10
+ default: r
11
+ };
12
+ if ((t = e(s)) && t.has(r)) return t.get(r);
13
+ for(var a in n = {
14
+ __proto__: null
15
+ }, o = Object.defineProperty && Object.getOwnPropertyDescriptor, r)if ("default" !== a && Object.prototype.hasOwnProperty.call(r, a)) {
16
+ var c = o ? Object.getOwnPropertyDescriptor(r, a) : null;
17
+ c && (c.get || c.set) ? Object.defineProperty(n, a, c) : n[a] = r[a];
97
18
  }
98
- return { valid: true };
19
+ return n.default = r, t && t.set(r, n), n;
99
20
  }
100
- async function createWorktree(options = {}) {
101
- const config = (0, config_1.loadConfig)({ cwd: options.cwd });
102
- const changeName = toChangeName(options.change);
103
- if (!changeName) {
104
- return {
105
- success: false,
106
- reason: 'missing-change',
107
- message: 'Missing required argument: --change <change-name>',
108
- };
109
- }
110
- // Validate config before use
111
- const configValidation = validateConfigForWorktree(config);
112
- if (!configValidation.valid) {
113
- return {
114
- success: false,
115
- reason: configValidation.reason,
116
- message: configValidation.message || 'Unknown config validation error',
117
- };
118
- }
119
- const projectRoot = config.projectRoot || process.cwd();
120
- const specRoot = config.specRootAbs || path.resolve(projectRoot, 'spec');
121
- const changeDir = path.resolve(specRoot, 'changes', changeName);
122
- const manifestPath = path.resolve(changeDir, 'manifest.json');
123
- if (!fs.existsSync(manifestPath)) {
124
- return {
125
- success: false,
126
- reason: 'manifest-not-found',
127
- message: `manifest.json not found. Run 'task-flow tasks --change ${changeName}' first.`,
128
- };
129
- }
130
- let manifestConfig;
21
+ async function s(e = {}) {
22
+ let r, t = (0, u.loadConfig)({
23
+ cwd: e.cwd
24
+ }), n = String(e.change || '').trim().replace(/[^a-zA-Z0-9-_]/g, '-').replace(/-+/g, '-').replace(/^-|-$/g, '');
25
+ if (!n) return {
26
+ success: !1,
27
+ reason: 'missing-change',
28
+ message: 'Missing required argument: --change <change-name>'
29
+ };
30
+ let o = t.projectRoot ? t.worktreesDirAbs ? {
31
+ valid: !0
32
+ } : {
33
+ valid: !1,
34
+ reason: 'missing-worktrees-dir',
35
+ message: 'Config missing worktreesDirAbs'
36
+ } : {
37
+ valid: !1,
38
+ reason: 'missing-project-root',
39
+ message: 'Config missing projectRoot'
40
+ };
41
+ if (!o.valid) return {
42
+ success: !1,
43
+ reason: o.reason,
44
+ message: o.message || 'Unknown config validation error'
45
+ };
46
+ let a = t.projectRoot || process.cwd(), f = t.specRootAbs || i.resolve(a, 'spec'), d = i.resolve(f, 'changes', n), m = i.resolve(d, 'manifest.json');
47
+ if (!c.existsSync(m)) return {
48
+ success: !1,
49
+ reason: 'manifest-not-found',
50
+ message: `manifest.json not found. Run 'task-flow tasks --change ${n}' first.`
51
+ };
131
52
  try {
132
- manifestConfig = JSON.parse(fs.readFileSync(manifestPath, 'utf8'));
133
- }
134
- catch (error) {
135
- const errorMessage = error instanceof Error ? error.message : 'Unknown error';
53
+ r = JSON.parse(c.readFileSync(m, 'utf8'));
54
+ } catch (r) {
55
+ let e = r instanceof Error ? r.message : 'Unknown error';
136
56
  return {
137
- success: false,
57
+ success: !1,
138
58
  reason: 'invalid-manifest',
139
- message: `Failed to parse manifest.json: ${errorMessage}`,
59
+ message: `Failed to parse manifest.json: ${e}`
140
60
  };
141
61
  }
142
- const taskId = manifestConfig.taskId || changeName;
143
- const taskType = manifestConfig.type || 'feat';
144
- const worktreeName = `harness-${taskType}-${taskId}`;
145
- const branchName = `${taskType}/${taskId}`;
146
- const worktreesDir = config.worktreesDirAbs || path.resolve(projectRoot, '.worktrees');
147
- const worktreePath = path.resolve(worktreesDir, worktreeName);
148
- if (fs.existsSync(worktreePath)) {
149
- return {
150
- success: false,
151
- reason: 'worktree-exists',
152
- message: `Worktree already exists: ${worktreePath}. Use --force to recreate.`,
153
- };
154
- }
155
- // Interactive confirmation
156
- if (!options.yes) {
157
- (0, interactive_1.printPreview)('Worktree Configuration', {
158
- 'Change Name': changeName,
159
- 'Task ID': taskId,
160
- 'Branch': branchName,
161
- 'Worktree Path': worktreePath,
162
- });
163
- const confirmed = await (0, interactive_1.confirm)({
164
- message: 'Create worktree with above configuration?',
165
- defaultYes: true,
166
- });
167
- if (!confirmed) {
168
- return {
169
- success: false,
170
- reason: 'user-cancelled',
171
- message: 'User cancelled the operation.',
172
- };
173
- }
174
- }
62
+ let p = r.taskId || n, y = r.type || 'feat', h = `harness-${y}-${p}`, k = `${y}/${p}`, w = t.worktreesDirAbs || i.resolve(a, '.worktrees'), v = i.resolve(w, h);
63
+ if (c.existsSync(v)) return {
64
+ success: !1,
65
+ reason: 'worktree-exists',
66
+ message: `Worktree already exists: ${v}. Use --force to recreate.`
67
+ };
68
+ if (!e.yes && ((0, g.printPreview)('Worktree Configuration', {
69
+ 'Change Name': n,
70
+ 'Task ID': p,
71
+ Branch: k,
72
+ 'Worktree Path': v
73
+ }), !await (0, g.confirm)({
74
+ message: 'Create worktree with above configuration?',
75
+ defaultYes: !0
76
+ }))) return {
77
+ success: !1,
78
+ reason: 'user-cancelled',
79
+ message: 'User cancelled the operation.'
80
+ };
175
81
  try {
176
- fs.mkdirSync(worktreesDir, { recursive: true });
177
- const mainBranch = getGitBranch(projectRoot);
178
- try {
179
- (0, child_process_1.execSync)(`git worktree add "${worktreePath}" -b ${branchName} ${mainBranch}`, {
180
- cwd: projectRoot,
181
- stdio: 'pipe',
182
- });
183
- }
184
- catch (error) {
185
- const errorMessage = error instanceof Error ? error.message : 'Unknown error';
186
- if (errorMessage.includes('already exists')) {
187
- (0, child_process_1.execSync)(`git worktree add "${worktreePath}" ${branchName}`, {
188
- cwd: projectRoot,
189
- stdio: 'pipe',
190
- });
191
- }
192
- else {
193
- throw error;
194
- }
195
- }
196
- const mainRepoRoot = projectRoot;
197
- const harnessInWorktree = path.resolve(worktreePath, '.harness');
198
- if (fs.existsSync(harnessInWorktree)) {
82
+ c.mkdirSync(w, {
83
+ recursive: !0
84
+ });
85
+ let e = function(e) {
199
86
  try {
200
- fs.rmSync(harnessInWorktree, { recursive: true, force: true });
87
+ return (0, l.execSync)('git rev-parse --abbrev-ref HEAD', {
88
+ cwd: e,
89
+ encoding: 'utf8'
90
+ }).trim();
91
+ } catch {
92
+ return 'main';
201
93
  }
202
- catch {
203
- // ignore
204
- }
205
- }
94
+ }(a);
206
95
  try {
207
- fs.symlinkSync(path.resolve(mainRepoRoot, '.harness'), harnessInWorktree, 'dir');
208
- }
209
- catch (symlinkError) {
210
- const errorMessage = symlinkError instanceof Error ? symlinkError.message : 'Unknown error';
211
- console.warn('[WORKTREE] Failed to create symlink for .harness:', errorMessage);
212
- fs.mkdirSync(harnessInWorktree, { recursive: true });
96
+ (0, l.execSync)(`git worktree add "${v}" -b ${k} ${e}`, {
97
+ cwd: a,
98
+ stdio: 'pipe'
99
+ });
100
+ } catch (e) {
101
+ if ((e instanceof Error ? e.message : 'Unknown error').includes('already exists')) (0, l.execSync)(`git worktree add "${v}" ${k}`, {
102
+ cwd: a,
103
+ stdio: 'pipe'
104
+ });
105
+ else throw e;
213
106
  }
214
- const gitignorePath = path.resolve(worktreePath, '.gitignore');
215
- let gitignoreContent = '';
216
- if (fs.existsSync(gitignorePath)) {
217
- gitignoreContent = fs.readFileSync(gitignorePath, 'utf8');
107
+ let r = i.resolve(v, '.harness');
108
+ if (c.existsSync(r)) try {
109
+ c.rmSync(r, {
110
+ recursive: !0,
111
+ force: !0
112
+ });
113
+ } catch {}
114
+ try {
115
+ c.symlinkSync(i.resolve(a, '.harness'), r, 'dir');
116
+ } catch (s) {
117
+ let e = s instanceof Error ? s.message : 'Unknown error';
118
+ console.warn('[WORKTREE] Failed to create symlink for .harness:', e), c.mkdirSync(r, {
119
+ recursive: !0
120
+ });
218
121
  }
219
- if (!gitignoreContent.includes('.harness/')) {
220
- const newContent = gitignoreContent.trim() + '\n\n# Harness\n.harness/\n';
221
- fs.writeFileSync(gitignorePath, newContent, 'utf8');
122
+ let s = i.resolve(v, '.gitignore'), t = '';
123
+ if (c.existsSync(s) && (t = c.readFileSync(s, 'utf8')), !t.includes('.harness/')) {
124
+ let e = t.trim() + '\n\n# Harness\n.harness/\n';
125
+ c.writeFileSync(s, e, 'utf8');
222
126
  }
223
127
  return {
224
- success: true,
225
- changeName,
226
- taskId,
227
- worktreeName,
228
- worktreePath,
229
- branchName,
230
- harnessLink: harnessInWorktree,
128
+ success: !0,
129
+ changeName: n,
130
+ taskId: p,
131
+ worktreeName: h,
132
+ worktreePath: v,
133
+ branchName: k,
134
+ harnessLink: r
231
135
  };
232
- }
233
- catch (error) {
234
- const errorMessage = error instanceof Error ? error.message : 'Unknown error';
136
+ } catch (r) {
137
+ let e = r instanceof Error ? r.message : 'Unknown error';
235
138
  return {
236
- success: false,
139
+ success: !1,
237
140
  reason: 'git-error',
238
- message: `Failed to create worktree: ${errorMessage}`,
141
+ message: `Failed to create worktree: ${e}`
239
142
  };
240
143
  }
241
144
  }
242
- function main() {
243
- const args = parseArgs(process.argv);
244
- createWorktree({
245
- cwd: args.cwd,
246
- change: args.change,
247
- force: args.force === true,
248
- yes: args.yes === true,
249
- }).then((result) => {
250
- if (!result.success) {
251
- console.error(`[WORKTREE] ${result.message}`);
252
- process.exit(1);
145
+ function t() {
146
+ let e = function(e) {
147
+ let r = {};
148
+ for(let s = 2; s < e.length; s += 1){
149
+ let t = e[s] || '';
150
+ if (!t.startsWith('--')) continue;
151
+ let n = t.slice(2), o = e[s + 1] || '';
152
+ if (!o || o.startsWith('--')) {
153
+ r[n] = !0;
154
+ continue;
155
+ }
156
+ r[n] = o, s += 1;
253
157
  }
254
- console.log('');
255
- console.log('[WORKTREE] Worktree created successfully!');
256
- console.log(` Change Name: ${result.changeName}`);
257
- console.log(` Task ID: ${result.taskId}`);
258
- console.log(` Worktree: ${result.worktreePath}`);
259
- console.log(` Branch: ${result.branchName}`);
260
- console.log(` Harness Link: ${result.harnessLink}`);
261
- console.log('');
262
- console.log('Next steps:');
263
- console.log(` cd ${result.worktreePath}`);
264
- console.log(' # Start implementing tasks');
265
- console.log('');
266
- process.exit(0);
158
+ return r;
159
+ }(process.argv);
160
+ s({
161
+ cwd: e.cwd,
162
+ change: e.change,
163
+ force: !0 === e.force,
164
+ yes: !0 === e.yes
165
+ }).then((e)=>{
166
+ e.success || (console.error(`[WORKTREE] ${e.message}`), process.exit(1)), console.log(''), console.log('[WORKTREE] Worktree created successfully!'), console.log(` Change Name: ${e.changeName}`), console.log(` Task ID: ${e.taskId}`), console.log(` Worktree: ${e.worktreePath}`), console.log(` Branch: ${e.branchName}`), console.log(` Harness Link: ${e.harnessLink}`), console.log(''), console.log('Next steps:'), console.log(` cd ${e.worktreePath}`), console.log(' # Start implementing tasks'), console.log(''), process.exit(0);
267
167
  });
268
168
  }
269
- if (require.main === module) {
270
- main();
271
- }
272
- exports.default = {
273
- createWorktree,
274
- main,
169
+ "use strict";
170
+ Object.defineProperty(exports, "__esModule", {
171
+ value: !0
172
+ });
173
+ var n = exports, o = {
174
+ get createWorktree () {
175
+ return s;
176
+ },
177
+ get default () {
178
+ return f;
179
+ },
180
+ get main () {
181
+ return t;
182
+ }
183
+ };
184
+ for(var a in o)Object.defineProperty(n, a, {
185
+ enumerable: !0,
186
+ get: Object.getOwnPropertyDescriptor(o, a).get
187
+ });
188
+ let c = /*#__PURE__*/ r(require("fs")), i = /*#__PURE__*/ r(require("path")), l = require("child_process"), u = require("../lib/config"), g = require("../lib/interactive");
189
+ require.main === module && t();
190
+ let f = {
191
+ createWorktree: s,
192
+ main: t
275
193
  };
@@ -1,61 +1,51 @@
1
+ function e(t) {
2
+ return "function" != typeof WeakMap ? null : (e = function(e) {
3
+ return new WeakMap();
4
+ })(t);
5
+ }
6
+ function t(e) {
7
+ let { prdPath: t } = e;
8
+ return t ? {
9
+ check: 'prd-exists',
10
+ exists: i.existsSync(t),
11
+ path: t
12
+ } : {
13
+ check: 'prd-exists',
14
+ exists: !1,
15
+ reason: 'missing-prd-path'
16
+ };
17
+ }
1
18
  "use strict";
2
- /**
3
- * hooks/check-prd-exists.ts
4
- * Hook to check if product-requirement.md exists before generating design.md
5
- */
6
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
7
- if (k2 === undefined) k2 = k;
8
- var desc = Object.getOwnPropertyDescriptor(m, k);
9
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
10
- desc = { enumerable: true, get: function() { return m[k]; } };
19
+ Object.defineProperty(exports, "__esModule", {
20
+ value: !0
21
+ });
22
+ var r = exports, n = {
23
+ get default () {
24
+ return u;
25
+ },
26
+ get run () {
27
+ return t;
11
28
  }
12
- Object.defineProperty(o, k2, desc);
13
- }) : (function(o, m, k, k2) {
14
- if (k2 === undefined) k2 = k;
15
- o[k2] = m[k];
16
- }));
17
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
18
- Object.defineProperty(o, "default", { enumerable: true, value: v });
19
- }) : function(o, v) {
20
- o["default"] = v;
29
+ };
30
+ for(var o in n)Object.defineProperty(r, o, {
31
+ enumerable: !0,
32
+ get: Object.getOwnPropertyDescriptor(n, o).get
21
33
  });
22
- var __importStar = (this && this.__importStar) || (function () {
23
- var ownKeys = function(o) {
24
- ownKeys = Object.getOwnPropertyNames || function (o) {
25
- var ar = [];
26
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
27
- return ar;
28
- };
29
- return ownKeys(o);
30
- };
31
- return function (mod) {
32
- if (mod && mod.__esModule) return mod;
33
- var result = {};
34
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
35
- __setModuleDefault(result, mod);
36
- return result;
34
+ let i = /*#__PURE__*/ function(t) {
35
+ var r, n, o;
36
+ if (t && t.__esModule) return t;
37
+ if (null === t || "object" != typeof t && "function" != typeof t) return {
38
+ default: t
37
39
  };
38
- })();
39
- Object.defineProperty(exports, "__esModule", { value: true });
40
- exports.run = run;
41
- const fs = __importStar(require("fs"));
42
- function run(context) {
43
- const { prdPath } = context;
44
- if (!prdPath) {
45
- return {
46
- check: 'prd-exists',
47
- exists: false,
48
- reason: 'missing-prd-path',
49
- };
40
+ if ((r = e(void 0)) && r.has(t)) return r.get(t);
41
+ for(var i in n = {
42
+ __proto__: null
43
+ }, o = Object.defineProperty && Object.getOwnPropertyDescriptor, t)if ("default" !== i && Object.prototype.hasOwnProperty.call(t, i)) {
44
+ var u = o ? Object.getOwnPropertyDescriptor(t, i) : null;
45
+ u && (u.get || u.set) ? Object.defineProperty(n, i, u) : n[i] = t[i];
50
46
  }
51
- const exists = fs.existsSync(prdPath);
52
- return {
53
- check: 'prd-exists',
54
- exists,
55
- path: prdPath,
56
- };
57
- }
58
- exports.default = {
59
- run,
60
- name: 'check-prd-exists',
47
+ return n.default = t, r && r.set(t, n), n;
48
+ }(require("fs")), u = {
49
+ run: t,
50
+ name: 'check-prd-exists'
61
51
  };