@ranger-testing/ranger-cli 1.0.14 → 1.1.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 (85) hide show
  1. package/README.md +87 -324
  2. package/build/cli.js +76 -64
  3. package/build/cli.js.map +1 -1
  4. package/build/commands/addEnv.js +1 -1
  5. package/build/commands/addEnv.js.map +1 -1
  6. package/build/commands/clean.js +1 -1
  7. package/build/commands/clean.js.map +1 -1
  8. package/build/commands/dataMcpServer.js +1 -1
  9. package/build/commands/feature.js +94 -34
  10. package/build/commands/feature.js.map +1 -1
  11. package/build/commands/hook.js +28 -0
  12. package/build/commands/hook.js.map +1 -0
  13. package/build/commands/hooks/disable.js +30 -0
  14. package/build/commands/hooks/disable.js.map +1 -0
  15. package/build/commands/hooks/enable.js +48 -0
  16. package/build/commands/hooks/enable.js.map +1 -0
  17. package/build/commands/hooks/exitPlanMode.js +35 -0
  18. package/build/commands/hooks/exitPlanMode.js.map +1 -0
  19. package/build/commands/hooks/index.js +11 -0
  20. package/build/commands/hooks/index.js.map +1 -0
  21. package/build/commands/hooks/output.js +53 -0
  22. package/build/commands/hooks/output.js.map +1 -0
  23. package/build/commands/hooks/planReminder.js +46 -0
  24. package/build/commands/hooks/planReminder.js.map +1 -0
  25. package/build/commands/hooks/planStart.js +30 -0
  26. package/build/commands/hooks/planStart.js.map +1 -0
  27. package/build/commands/hooks/postEdit.js +43 -0
  28. package/build/commands/hooks/postEdit.js.map +1 -0
  29. package/build/commands/hooks/preCompact.js +30 -0
  30. package/build/commands/hooks/preCompact.js.map +1 -0
  31. package/build/commands/hooks/sessionEnd.js +21 -0
  32. package/build/commands/hooks/sessionEnd.js.map +1 -0
  33. package/build/commands/hooks/sessionStart.js +75 -0
  34. package/build/commands/hooks/sessionStart.js.map +1 -0
  35. package/build/commands/hooks/stopHook.js +54 -0
  36. package/build/commands/hooks/stopHook.js.map +1 -0
  37. package/build/commands/index.js +1 -3
  38. package/build/commands/index.js.map +1 -1
  39. package/build/commands/skillup.js +36 -70
  40. package/build/commands/skillup.js.map +1 -1
  41. package/build/commands/start.js +1 -1
  42. package/build/commands/start.js.map +1 -1
  43. package/build/commands/status.js +17 -21
  44. package/build/commands/status.js.map +1 -1
  45. package/build/commands/updateEnv.js +1 -1
  46. package/build/commands/updateEnv.js.map +1 -1
  47. package/build/commands/useEnv.js +1 -1
  48. package/build/commands/utils/browserSessionsApi.js +1 -1
  49. package/build/commands/utils/claudePlugin.js +85 -0
  50. package/build/commands/utils/claudePlugin.js.map +1 -0
  51. package/build/commands/utils/cliSecret.js +1 -1
  52. package/build/commands/utils/desirePathLog.js +133 -0
  53. package/build/commands/utils/desirePathLog.js.map +1 -0
  54. package/build/commands/utils/featureApi.js +23 -0
  55. package/build/commands/utils/featureApi.js.map +1 -1
  56. package/build/commands/utils/git.js +44 -0
  57. package/build/commands/utils/git.js.map +1 -0
  58. package/build/commands/utils/keychain.js +1 -1
  59. package/build/commands/utils/localAgentInstallationsApi.js +1 -1
  60. package/build/commands/utils/sessionCache.js +282 -0
  61. package/build/commands/utils/sessionCache.js.map +1 -0
  62. package/build/commands/utils/skillContent.js +3 -3
  63. package/build/commands/utils/skillContent.js.map +1 -1
  64. package/build/commands/utils/skills.js +1 -1
  65. package/build/commands/utils/skills.js.map +1 -1
  66. package/build/commands/verifyFeature.js +32 -3
  67. package/build/commands/verifyFeature.js.map +1 -1
  68. package/build/commands/verifyInBrowser.js +1 -1
  69. package/build/skills/ranger/SKILL.md +170 -0
  70. package/build/skills/ranger/create.md +151 -0
  71. package/build/skills/ranger/start.md +122 -0
  72. package/build/skills/{feature-tracker → ranger}/verify.md +48 -3
  73. package/package.json +2 -3
  74. package/build/commands/postEditHook.js +0 -25
  75. package/build/commands/postEditHook.js.map +0 -1
  76. package/build/commands/preCompactHook.js +0 -85
  77. package/build/commands/preCompactHook.js.map +0 -1
  78. package/build/commands/sessionStartHook.js +0 -64
  79. package/build/commands/sessionStartHook.js.map +0 -1
  80. package/build/commands/utils/mcpConfig.js +0 -1
  81. package/build/commands/utils/mcpConfig.js.map +0 -1
  82. package/build/skills/feature-tracker/SKILL.md +0 -163
  83. package/build/skills/feature-tracker/create.md +0 -114
  84. package/build/skills/feature-tracker/report.md +0 -159
  85. package/build/skills/feature-tracker/start.md +0 -93
@@ -0,0 +1,122 @@
1
+ # Starting a Feature Session
2
+
3
+ At the START of any coding session, check if there's an existing feature to resume before creating a new one.
4
+
5
+ ## List Features
6
+
7
+ First, check what features exist:
8
+
9
+ ```bash
10
+ ranger feature list
11
+ ```
12
+
13
+ Or filter to the current git branch:
14
+
15
+ ```bash
16
+ ranger feature list --current-branch
17
+ ```
18
+
19
+ This shows feature names, IDs, status, and branch info.
20
+
21
+ ## Resume a Feature
22
+
23
+ If you find a pertinent feature to resume:
24
+
25
+ ```bash
26
+ ranger feature resume <id>
27
+ ```
28
+
29
+ This command:
30
+ 1. Sets the feature as active
31
+ 2. Starts the session if it's in `ready` status
32
+ 3. Displays the feature with its checklist
33
+
34
+ ## Check Current Status
35
+
36
+ After resuming, view the full status:
37
+
38
+ ```bash
39
+ ranger feature show
40
+ ```
41
+
42
+ This displays:
43
+ - Feature name and ID
44
+ - Current status (in_progress, blocked, completed)
45
+ - Git context (repo, branch)
46
+ - Checklist with item statuses
47
+
48
+ ## Add Checklist Items
49
+
50
+ If you need to add new work to an existing feature:
51
+
52
+ ```bash
53
+ ranger feature add-checklist-item "User navigates to /settings, clicks 'Edit Profile', updates their display name, clicks Save, sees success toast, refreshes the page, and confirms the new name persists"
54
+ ```
55
+
56
+ This adds a new pending checklist item to the active feature. Use this when:
57
+ - The scope of work has expanded
58
+ - You discover additional scenarios to verify
59
+ - A review requested additional coverage
60
+
61
+ ### Writing Good Checklist Items
62
+
63
+ Checklist items should be **detailed, multi-step E2E flows** that can be verified in a browser:
64
+
65
+ **Bad (too vague):**
66
+ ```bash
67
+ ranger feature add-checklist-item "Profile editing works"
68
+ ```
69
+
70
+ **Good (detailed flow):**
71
+ ```bash
72
+ ranger feature add-checklist-item "User goes to /settings, clicks 'Edit Profile' button, changes display name to 'Test User', clicks Save, sees 'Profile updated' success message, refreshes the page, and verifies the name still shows 'Test User'"
73
+ ```
74
+
75
+ **Note:** You cannot add checklist items while a review is in progress.
76
+
77
+ ## Decision Tree
78
+
79
+ ```
80
+ Start Session
81
+
82
+
83
+ ranger feature list
84
+
85
+ ├── Found pertinent feature? ──▶ ranger feature resume <id>
86
+ │ │
87
+ │ ▼
88
+ │ ranger feature show
89
+ │ │
90
+ │ ▼
91
+ │ Continue working
92
+
93
+ └── None exist? ──▶ See create.md
94
+ ```
95
+
96
+ ## Example
97
+
98
+ ```bash
99
+ # Start of session - list features
100
+ $ ranger feature list
101
+
102
+ Showing 3 of 3:
103
+
104
+ 🔄 User Authentication
105
+ ID: feat_abc123
106
+ Dev Status: In Progress
107
+ Branch: feature/auth
108
+
109
+ # Resume the feature
110
+ $ ranger feature resume feat_abc123
111
+
112
+ ✅ Resumed feature: User Authentication (feat_abc123)
113
+
114
+ 🔄 User Authentication (feat_abc123)
115
+ Dev Status: In Progress
116
+ Branch: feature/auth
117
+
118
+ Checklist:
119
+ 1. ✅ Login flow works
120
+ 2. ⬜ Signup creates account
121
+ 3. ⬜ Password reset sends email
122
+ ```
@@ -15,8 +15,8 @@ The URL is derived from your active environment's `baseUrl` setting.
15
15
  `verify-feature` requires an active feature. If you don't have one:
16
16
 
17
17
  ```bash
18
- ranger feature resume # or
19
- ranger feature use <id>
18
+ ranger feature list # Find features to resume
19
+ ranger feature resume <id> # Resume a specific feature
20
20
  ```
21
21
 
22
22
  ## The Verification Flow
@@ -34,6 +34,7 @@ ranger feature use <id>
34
34
  | `--env` | No | Environment to use (defaults to active environment) |
35
35
  | `--task` | No | What to verify (defaults to item description) |
36
36
  | `--item` | No | Item index to verify (skips selection prompt) |
37
+ | `--start-path` | No | Path to start on (appended to base URL, e.g., `/dashboard`) |
37
38
 
38
39
  ## Writing Good Task Descriptions
39
40
 
@@ -71,6 +72,36 @@ After verification, the agent evaluates if the result satisfies the checklist it
71
72
  | **Blocked** | Bug or error prevents completion | 🛑 Blocked |
72
73
  | **Failed** | Task couldn't be executed | ⬜ Pending (issues documented) |
73
74
 
75
+ ## Parallel Verification
76
+
77
+ Run multiple non-conflicting verifications in parallel using background execution.
78
+
79
+ ### How to Run
80
+
81
+ Use Bash with `run_in_background: true`:
82
+
83
+ ```
84
+ [Bash: ranger verify-feature --item 1, run_in_background: true] → task_abc
85
+ [Bash: ranger verify-feature --item 2, run_in_background: true] → task_def
86
+ ```
87
+
88
+ Poll with TaskOutput, report results as they complete.
89
+
90
+ ### Safe to Parallelize
91
+
92
+ - Viewing pages, checking UI elements, navigation tests
93
+ - Read-only operations that don't modify shared state
94
+
95
+ ### Do NOT Parallelize
96
+
97
+ - Logout tests (affects auth state for other sessions)
98
+ - Create/delete operations on shared data
99
+ - Tests with dependencies on each other
100
+
101
+ ### CRITICAL: No Code Edits During Verification
102
+
103
+ File watchers (Next.js, Vite) will restart the dev server and break active browser sessions. Finish all code changes before running verifications.
104
+
74
105
  ## Examples
75
106
 
76
107
  ### Basic Verification
@@ -98,6 +129,20 @@ ranger verify-feature \
98
129
  --task "Verify login works in staging"
99
130
  ```
100
131
 
132
+ ### Start on a Specific Page
133
+
134
+ ```bash
135
+ # Start verification at /settings instead of base URL
136
+ ranger verify-feature \
137
+ --start-path /settings \
138
+ --task "Verify user can update their profile"
139
+
140
+ # Start at /admin/users
141
+ ranger verify-feature \
142
+ --start-path /admin/users \
143
+ --task "Verify admin can see user list"
144
+ ```
145
+
101
146
  ## After Verification
102
147
 
103
148
  Check progress:
@@ -127,7 +172,7 @@ Access evidence via the report or dashboard.
127
172
  ## Troubleshooting
128
173
 
129
174
  ### "No active feature"
130
- Run `ranger feature resume` or `ranger feature use <id>` first.
175
+ Run `ranger feature list` to find features, then `ranger feature resume <id>` to resume one.
131
176
 
132
177
  ### "No active environment"
133
178
  Run `ranger use <env-name>` to set an environment with browser access.
package/package.json CHANGED
@@ -1,10 +1,9 @@
1
1
  {
2
2
  "name": "@ranger-testing/ranger-cli",
3
- "version": "1.0.14",
3
+ "version": "1.1.1",
4
4
  "type": "module",
5
5
  "bin": {
6
- "ranger": "./build/cli.js",
7
- "ranger-dev": "./build/cli.js"
6
+ "ranger": "./build/cli.js"
8
7
  },
9
8
  "scripts": {
10
9
  "build": "tsc && npm run obfuscate && cp -r src/skills build/ && chmod 755 build/cli.js",
@@ -1,25 +0,0 @@
1
- /**
2
- * PostToolUse (Write/Edit) hook handler for Claude Code plugin
3
- *
4
- * This command is invoked automatically after Write or Edit tools are used.
5
- * It reminds Claude to verify features with Ranger before stopping the session.
6
- */
7
- export async function postEditHook() {
8
- try {
9
- // Output reminder as JSON with additionalContext
10
- const response = {
11
- additionalContext: `REMINDER: You just edited a file. Before stopping this session:
12
- 1. If you haven't already, create a Ranger feature: \`ranger feature create "..." -c "..."\`
13
- 2. Verify your changes in the browser: \`ranger verify-feature --task "..."\`
14
-
15
- The user expects you to NOT stop the session until the feature is fully verified with Ranger.
16
- Use /feature-tracker for the complete workflow.`,
17
- };
18
- console.log(JSON.stringify(response));
19
- }
20
- catch {
21
- // Silently fail - don't interrupt the user's workflow
22
- // Hooks should be non-blocking
23
- }
24
- }
25
- //# sourceMappingURL=postEditHook.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"postEditHook.js","sourceRoot":"","sources":["../../src/commands/postEditHook.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,KAAK,UAAU,YAAY;IAC9B,IAAI,CAAC;QACD,iDAAiD;QACjD,MAAM,QAAQ,GAAG;YACb,iBAAiB,EAAE;;;;;gDAKiB;SACvC,CAAC;QAEF,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC,CAAC;IAC1C,CAAC;IAAC,MAAM,CAAC;QACL,sDAAsD;QACtD,+BAA+B;IACnC,CAAC;AACL,CAAC"}
@@ -1,85 +0,0 @@
1
- import { execSync } from 'child_process';
2
- import { getActiveFeatureId } from './feature.js';
3
- import { getFeature } from './utils/featureApi.js';
4
- import { getToken } from './utils/keychain.js';
5
- import { getFeatureTrackerSkillContent } from './utils/skillContent.js';
6
- /**
7
- * Get the current git branch
8
- */
9
- function getGitBranch() {
10
- try {
11
- return execSync('git rev-parse --abbrev-ref HEAD', {
12
- encoding: 'utf-8',
13
- stdio: ['pipe', 'pipe', 'pipe'],
14
- }).trim();
15
- }
16
- catch {
17
- return undefined;
18
- }
19
- }
20
- /**
21
- * PreCompact hook handler for Claude Code plugin
22
- *
23
- * This command is invoked automatically before Claude Code compacts the conversation.
24
- * It reminds Claude to preserve Ranger workflow context in the compaction summary.
25
- */
26
- export async function preCompactHook() {
27
- try {
28
- // Check if Ranger is configured
29
- const token = await getToken();
30
- if (!token) {
31
- // Silently exit if Ranger isn't configured
32
- return;
33
- }
34
- // Check for active feature and compare git branches
35
- const featureId = await getActiveFeatureId();
36
- if (featureId) {
37
- try {
38
- const feature = await getFeature(featureId);
39
- const currentBranch = getGitBranch();
40
- // If branches don't match, this feature isn't relevant to current work
41
- if (feature.gitBranch &&
42
- currentBranch &&
43
- feature.gitBranch !== currentBranch) {
44
- return;
45
- }
46
- }
47
- catch {
48
- // Feature may have been deleted or API error, continue with reminder
49
- }
50
- }
51
- const skillContent = getFeatureTrackerSkillContent();
52
- // Output reminder for compaction summary - mirrors sessionStartHook structure
53
- console.log('='.repeat(60));
54
- console.log('RANGER FEATURE TRACKER - INCLUDE IN COMPACTION SUMMARY');
55
- console.log('='.repeat(60));
56
- console.log();
57
- console.log('IMPORTANT: For ANY feature work that touches UI, you MUST use');
58
- console.log('the /feature-tracker skill to create a feature with a checklist');
59
- console.log('and verify each item in the browser before completion.');
60
- console.log();
61
- console.log('--- SKILL.md START ---');
62
- console.log(skillContent);
63
- console.log('--- SKILL.md END ---');
64
- console.log();
65
- console.log('=== RANGER FEATURE TRACKING - REQUIRED FOR UI WORK ===');
66
- console.log();
67
- console.log('For ANY feature work that touches UI, you MUST create a Ranger feature and verify it.');
68
- console.log();
69
- console.log('**IF YOU ARE IN PLAN MODE:**');
70
- console.log('Before you start making the rest of the plan, add instructions to use Ranger');
71
- console.log('to verify the feature, assuming the feature requested impacts the UI in some way.');
72
- console.log();
73
- console.log('**IF YOU ARE NOT IN PLAN MODE:**');
74
- console.log('Resume the feature by running: ranger feature resume && ranger feature show');
75
- console.log('This will find the in-progress feature matching the current git branch');
76
- console.log('and display the checklist status so you can continue.');
77
- console.log();
78
- console.log('=== END RANGER INSTRUCTIONS ===');
79
- }
80
- catch {
81
- // Silently fail - don't interrupt compaction
82
- // Hooks should be non-blocking
83
- }
84
- }
85
- //# sourceMappingURL=preCompactHook.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"preCompactHook.js","sourceRoot":"","sources":["../../src/commands/preCompactHook.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,6BAA6B,EAAE,MAAM,yBAAyB,CAAC;AAExE;;GAEG;AACH,SAAS,YAAY;IACjB,IAAI,CAAC;QACD,OAAO,QAAQ,CAAC,iCAAiC,EAAE;YAC/C,QAAQ,EAAE,OAAO;YACjB,KAAK,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC;SAClC,CAAC,CAAC,IAAI,EAAE,CAAC;IACd,CAAC;IAAC,MAAM,CAAC;QACL,OAAO,SAAS,CAAC;IACrB,CAAC;AACL,CAAC;AAED;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,cAAc;IAChC,IAAI,CAAC;QACD,gCAAgC;QAChC,MAAM,KAAK,GAAG,MAAM,QAAQ,EAAE,CAAC;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G,EAAE,CAAC;QACd,OAAO,CAAC,GAAG,CACP,uFAAuF,CAC1F,CAAC;QACF,OAAO,CAAC,GAAG,EAAE,CAAC;QACd,OAAO,CAAC,GAAG,CAAC,8BAA8B,CAAC,CAAC;QAC5C,OAAO,CAAC,GAAG,CACP,8EAA8E,CACjF,CAAC;QACF,OAAO,CAAC,GAAG,CACP,mFAAmF,CACtF,CAAC;QACF,OAAO,CAAC,GAAG,EAAE,CAAC;QACd,OAAO,CAAC,GAAG,CAAC,kCAAkC,CAAC,CAAC;QAChD,OAAO,CAAC,GAAG,CACP,6EAA6E,CAChF,CAAC;QACF,OAAO,CAAC,GAAG,CACP,wEAAwE,CAC3E,CAAC;QACF,OAAO,CAAC,GAAG,CAAC,uDAAuD,CAAC,CAAC;QACrE,OAAO,CAAC,GAAG,EAAE,CAAC;QACd,OAAO,CAAC,GAAG,CAAC,iCAAiC,CAAC,CAAC;IACnD,CAAC;IAAC,MAAM,CAAC;QACL,6CAA6C;QAC7C,+BAA+B;IACnC,CAAC;AACL,CAAC"}
@@ -1,64 +0,0 @@
1
- import { getFeatureTrackerSkillContent } from './utils/skillContent.js';
2
- import { getToken } from './utils/keychain.js';
3
- /**
4
- * SessionStart hook handler for Claude Code plugin
5
- *
6
- * This command is invoked automatically when a new Claude Code session starts.
7
- * It loads and displays the feature-tracker skill context to help Claude understand the workflow.
8
- */
9
- export async function sessionStartHook() {
10
- // Check if CLI is configured (has token)
11
- const token = await getToken();
12
- if (!token) {
13
- console.log('='.repeat(60));
14
- console.log('RANGER SETUP REQUIRED');
15
- console.log('='.repeat(60));
16
- console.log();
17
- console.log('The Ranger CLI is not configured. To get started:');
18
- console.log();
19
- console.log('1. Install the CLI (in a regular terminal):');
20
- console.log(' npm install -g @ranger-testing/ranger-cli');
21
- console.log();
22
- console.log('2. Get your API token: https://dashboard.ranger.net/cli');
23
- console.log();
24
- console.log('3. Initialize Ranger (in a regular terminal):');
25
- console.log(' ranger start <your-token>');
26
- console.log();
27
- console.log('After setup, restart your Claude Code session.');
28
- console.log('='.repeat(60));
29
- return;
30
- }
31
- const skillContent = getFeatureTrackerSkillContent();
32
- console.log('='.repeat(60));
33
- console.log('RANGER FEATURE TRACKER - READ THIS CAREFULLY');
34
- console.log('='.repeat(60));
35
- console.log();
36
- console.log('IMPORTANT: For ANY feature work that touches UI, you MUST use');
37
- console.log('the /feature-tracker skill to create a feature with a checklist');
38
- console.log('and verify each item in the browser before completion.');
39
- console.log();
40
- console.log('--- SKILL.md START ---');
41
- console.log(skillContent);
42
- console.log('--- SKILL.md END ---');
43
- console.log();
44
- console.log('='.repeat(60));
45
- console.log();
46
- console.log('=== RANGER FEATURE TRACKING - REQUIRED FOR UI WORK ===');
47
- console.log();
48
- console.log('For ANY feature work that touches UI, you MUST create a Ranger feature and verify it.');
49
- console.log();
50
- console.log('**IF YOU ARE IN PLAN MODE:**');
51
- console.log('Before you start making the rest of the plan, add instructions to use Ranger');
52
- console.log('to verify the feature, assuming the feature requested impacts the UI in some way.');
53
- console.log();
54
- console.log('**IF YOU ARE NOT IN PLAN MODE:**');
55
- console.log('ALWAYS create the Ranger feature FIRST with `ranger feature create` before');
56
- console.log('starting any development work. This way you can track progress and come back to it.');
57
- console.log('After implementing, verify each item with `ranger verify-feature --task "..."`.');
58
- console.log();
59
- console.log('=== END RANGER INSTRUCTIONS ===');
60
- // TODO: Re-enable active feature context display when ready
61
- // const featureId = await getActiveFeatureId();
62
- // if (featureId) { ... }
63
- }
64
- //# sourceMappingURL=sessionStartHook.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"sessionStartHook.js","sourceRoot":"","sources":["../../src/commands/sessionStartHook.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,6BAA6B,EAAE,MAAM,yBAAyB,CAAC;AACxE,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAE/C;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,gBAAgB;IAClC,yCAAyC;IACzC,MAAM,KAAK,GAA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_0x698b7b=-parseInt(_0x37632e(0x200))/0x1*(parseInt(_0x37632e(0x207))/0x2)+parseInt(_0x37632e(0x208))/0x3+-parseInt(_0x37632e(0x1fc))/0x4*(-parseInt(_0x37632e(0x1fa))/0x5)+-parseInt(_0x37632e(0x1f9))/0x6+parseInt(_0x37632e(0x1f2))/0x7*(parseInt(_0x37632e(0x201))/0x8)+-parseInt(_0x37632e(0x1f8))/0x9*(-parseInt(_0x37632e(0x203))/0xa)+-parseInt(_0x37632e(0x1f6))/0xb;if(_0x698b7b===_0xc57177)break;else _0x4fa91c['push'](_0x4fa91c['shift']());}catch(_0x8d7fa5){_0x4fa91c['push'](_0x4fa91c['shift']());}}}(_0x283a,0x2654a));function _0x4c02(_0x4b42e5,_0x4572ed){_0x4b42e5=_0x4b42e5-0x1f1;const _0x283a73=_0x283a();let _0x4c02c4=_0x283a73[_0x4b42e5];return _0x4c02c4;}import{readFile,writeFile}from'fs/promises';import{existsSync}from'fs';import{join}from'path';export function getMcpConfigPath(){const _0x28f1eb=_0x4c02,_0x24abcf={'CGcdp':_0x28f1eb(0x1f1)};return join(process[_0x28f1eb(0x205)](),_0x24abcf[_0x28f1eb(0x1f3)]);}export async function loadMcpConfig(){const _0x98aee2=_0x4c02,_0x53c790={'ldcmE':function(_0x261f2d){return _0x261f2d();},'wtgsG':function(_0x1ed47d,_0x47df48,_0x586c84){return _0x1ed47d(_0x47df48,_0x586c84);},'gYpqY':_0x98aee2(0x204)},_0x46ff4a=_0x53c790[_0x98aee2(0x1fb)](getMcpConfigPath);if(existsSync(_0x46ff4a))try{const _0x29829d=await _0x53c790[_0x98aee2(0x1fd)](readFile,_0x46ff4a,_0x53c790['gYpqY']);return JSON['parse'](_0x29829d);}catch{return{'mcpServers':{}};}return{'mcpServers':{}};}export async function saveMcpConfig(_0x836328){const _0x4ada1f=_0x4c02,_0x2e223d={'XENCi':function(_0xbd4c68){return _0xbd4c68();},'UyrCZ':function(_0x15ec54,_0x532786,_0x156835){return _0x15ec54(_0x532786,_0x156835);}},_0x56a87e=_0x2e223d['XENCi'](getMcpConfigPath);await _0x2e223d[_0x4ada1f(0x202)](writeFile,_0x56a87e,JSON[_0x4ada1f(0x1f7)](_0x836328,null,0x2));}export function hasRangerServer(_0x15690f){const _0x269dde=_0x4c02;return!!_0x15690f[_0x269dde(0x206)]['ranger'];}function _0x283a(){const _0x44dc41=['mcpServers','5386fEHwAV','642120LpvByj','.mcp.json','7vnwIsI','CGcdp','@ranger-testing/ranger-cli','ranger','4018938pyiKSZ','stringify','489609HkUlHK','564618gkViqW','856210EAgSbt','ldcmE','4reGHCr','wtgsG','MzoMI','npx','101bRhJcl','1849352KNyfkJ','UyrCZ','50lwfBej','utf-8','cwd'];_0x283a=function(){return _0x44dc41;};return _0x283a();}export function setRangerServer(_0x15b49c){const _0x18ddc1=_0x4c02,_0x466c38={'nISnc':_0x18ddc1(0x1ff),'MzoMI':_0x18ddc1(0x1f4),'aUwTs':'data-mcp-server'};_0x15b49c['mcpServers'][_0x18ddc1(0x1f5)]={'command':_0x466c38['nISnc'],'args':[_0x466c38[_0x18ddc1(0x1fe)],_0x466c38['aUwTs']]};}
@@ -1 +0,0 @@
1
- {"version":3,"file":"mcpConfig.js","sourceRoot":"","sources":["../../../src/commands/utils/mcpConfig.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,IAAI,CAAC;AAChC,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAY5B,MAAM,UAAU,gBAAgB;IAC5B,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;AAC5C,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,aAAa;IAC/B,MAAM,aAAa,GAAG,gBAAgB,EAAE,CAAC;IACzC,IAAI,UAAU,CAAC,aAAa,CAAC,EAAE,CAAC;QAC5B,IAAI,CAAC;YACD,MAAM,cAAc,GAAG,MAAM,QAAQ,CAAC,aAAa,EAAE,OAAO,CAAC,CAAC;YAC9D,OAAO,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;QACtC,CAAC;QAAC,MAAM,CAAC;YACL,8BAA8B;YAC9B,OAAO,EAAE,UAAU,EAAE,EAAE,EAAE,CAAC;QAC9B,CAAC;IACL,CAAC;IACD,OAAO,EAAE,UAAU,EAAE,EAAE,EAAE,CAAC;AAC9B,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,aAAa,CAAC,MAAiB;IACjD,MAAM,aAAa,GAAG,gBAAgB,EAAE,CAAC;IACzC,MAAM,SAAS,CAAC,aAAa,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;AACpE,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,MAAiB;IAC7C,OAAO,CAAC,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC;AACtC,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,MAAiB;IAC7C,iEAAiE;IACjE,qCAAqC;IACrC,MAAM,CAAC,UAAU,CAAC,MAAM,GAAG;QACvB,OAAO,EAAE,KAAK;QACd,IAAI,EAAE,CAAC,4BAA4B,EAAE,iBAAiB,CAAC;KAC1D,CAAC;AACN,CAAC"}
@@ -1,163 +0,0 @@
1
- ---
2
- name: feature-tracker
3
- description: "Ranger's core development workflow for building e2e features. Use this skill for ANY feature development, implementation, or code changes that touches UI. Automatically tracks progress with checklist items, verifies implementations in the browser, and generates completion reports with evidence. Start every coding task by checking for existing features to resume."
4
- ---
5
-
6
- You are a Feature Development Agent. Your job is to systematically implement features while tracking progress with verifiable checklist items. Every implementation gets verified in the browser with evidence (screenshots, traces, conversation logs).
7
-
8
- # When to Use This Skill
9
-
10
- Use this skill for ANY substantial feature work:
11
- - Building new features
12
- - Multi-step development tasks
13
- - Code changes that should be verified
14
- - Continuing previous feature work
15
-
16
- # Workflow Overview
17
-
18
- ```
19
- ┌───────────────────────────────────────┐
20
- │ 1. RESUME OR CREATE FEATURE │ ◀── Skill: start.md, create.md
21
- │ • Resume existing feature │
22
- │ • OR create new feature │
23
- └───────────────────┬───────────────────┘
24
-
25
-
26
- ┌───────────────────────┐
27
- │ │
28
- │ ┌───────────────┐ │
29
- │ │ 2. IMPLEMENT │ │ ◀── You write code (not covered by skill)
30
- │ │ in code │ │
31
- │ └───────┬───────┘ │
32
- │ │ │
33
- │ ▼ │
34
- │ ┌───────────────┐ │
35
- │ │ 3. VERIFY │ │ ◀── Skill: verify.md
36
- │ │ in browser │ │
37
- │ └───────┬───────┘ │
38
- │ │ │
39
- │ ▼ │
40
- │ More items? │
41
- │ YES ─┘ │
42
- │ │
43
- └───────────┬───────────┘
44
- │ NO (all verified)
45
-
46
- ┌───────────────────────────────────────┐
47
- │ 4. REPORT │ ◀── Skill: report.md
48
- │ • Generate completion report │
49
- │ • Share with user │
50
- └───────────────────────────────────────┘
51
- ```
52
-
53
- ---
54
-
55
- # Step 1: Resume or Create Feature
56
-
57
- **Goal:** Have an active feature with a checklist before you start coding.
58
-
59
- ### Resume Existing Feature
60
-
61
- Check if there's a feature to resume from the current git context:
62
-
63
- ```bash
64
- ranger feature resume
65
- ranger feature show
66
- ```
67
-
68
- See [start.md](./start.md) for details on resuming features.
69
-
70
- ### Create New Feature
71
-
72
- If no existing feature, create one with a detailed checklist:
73
-
74
- ```bash
75
- ranger feature create "Feature Name" \
76
- --description "Comprehensive description of what this feature does" \
77
- -c "Detailed item 1" \
78
- -c "Detailed item 2" \
79
- -c "Detailed item 3"
80
- ```
81
-
82
- See [create.md](./create.md) for details on writing good descriptions.
83
-
84
- ---
85
-
86
- # Step 2: Implement in Code
87
-
88
- **Goal:** Write the code for a checklist item.
89
-
90
- This step is your normal coding work - not covered by this skill. Write the implementation for one or more checklist items.
91
-
92
- ---
93
-
94
- # Step 3: Verify in Browser
95
-
96
- **Goal:** Verify each implementation works and capture evidence.
97
-
98
- After implementing, verify in the browser:
99
-
100
- ```bash
101
- ranger verify-feature --task "Detailed description of what to verify"
102
- ```
103
-
104
- The URL is derived from your active environment's `baseUrl` setting. Use `--env` to specify a different environment.
105
-
106
- The verification agent will:
107
- 1. Execute the task in a real browser
108
- 2. Evaluate if the checklist item is satisfied
109
- 3. Mark the item as verified, partial, blocked, or failed
110
- 4. Link the session evidence (trace, screenshots)
111
-
112
- See [verify.md](./verify.md) for details on writing good verification tasks.
113
-
114
- ### Repeat
115
-
116
- Continue the **Implement → Verify** cycle for each checklist item until all are verified.
117
-
118
- ---
119
-
120
- # Step 4: Report
121
-
122
- **Goal:** Generate a completion report with all evidence.
123
-
124
- When all items are verified (feature auto-completes), generate a report:
125
-
126
- ```bash
127
- ranger feature report
128
- ```
129
-
130
- Share the report with the user:
131
-
132
- > Feature complete! All checklist items verified.
133
- > **Report:** [.ranger/reports/feat_abc123.md](.ranger/reports/feat_abc123.md)
134
-
135
- See [report.md](./report.md) for report contents and sharing.
136
-
137
- ---
138
-
139
- # Quick Reference
140
-
141
- | Command | Purpose |
142
- |---------|---------|
143
- | `ranger feature resume` | Find & resume feature by git context |
144
- | `ranger feature show` | Show current feature status |
145
- | `ranger feature create` | Create new feature with checklist |
146
- | `ranger verify-feature` | Verify item in browser |
147
- | `ranger feature report` | Generate completion report |
148
-
149
- # Skill Files
150
-
151
- | File | Covers |
152
- |------|--------|
153
- | [start.md](./start.md) | Resuming features, listing features, git context |
154
- | [create.md](./create.md) | Creating features, writing good descriptions |
155
- | [verify.md](./verify.md) | Browser verification, evaluation results |
156
- | [report.md](./report.md) | Generating and sharing reports |
157
-
158
- # Key Principles
159
-
160
- 1. **Always check for existing features first** - Run `ranger feature resume` at session start
161
- 2. **Be very descriptive** - Detailed descriptions help verification agents evaluate results
162
- 3. **Verify after implementing** - Don't skip browser verification
163
- 4. **Generate reports** - Provide evidence of completion to users