@dev_desh/flux-cap 0.1.0

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 (3) hide show
  1. package/README.md +234 -0
  2. package/dist/index.js +25162 -0
  3. package/package.json +38 -0
package/README.md ADDED
@@ -0,0 +1,234 @@
1
+ # πŸ… flux-cap
2
+
3
+ **A git-aware CLI context manager for ADHD developers**
4
+
5
+ > *Never lose track of what you were coding after interruptions again.*
6
+
7
+ flux-cap is a terminal-native tool that captures your thoughts, tracks your context, and integrates seamlessly with your git workflow. Built specifically for developers who context-switch frequently.
8
+
9
+ ## ✨ Features
10
+
11
+ ### 🧠 **Brain Dump System**
12
+ - Instantly capture thoughts without breaking flow: `flux dump "fix auth validation bug"`
13
+ - Git-aware context tracking (branch, working directory, uncommitted changes)
14
+ - Monthly file organization for easy browsing
15
+ - Privacy-first design - you control what gets tracked
16
+
17
+ ### πŸ” **Intelligent Search**
18
+ - Fuzzy search across all your brain dumps: `flux search "auth"`
19
+ - Configurable search fields (message, branch, working directory)
20
+ - Smart result ranking with relevance scores
21
+ - Multi-month search with automatic limits
22
+
23
+ ### πŸ”’ **Privacy Controls**
24
+ - Choose what information to track during setup
25
+ - Hide working directory paths, branch names, or git status
26
+ - All data stored locally in human-readable JSON
27
+ - Edit or delete your data anytime
28
+
29
+ ### πŸš€ **Git Integration**
30
+ - Automatic branch context detection
31
+ - Uncommitted changes tracking
32
+ - Smart .gitignore management
33
+ - Works in non-git directories too
34
+
35
+ ## πŸ“¦ Installation
36
+
37
+ ```bash
38
+ # Clone the repository
39
+ git clone https://github.com/yourusername/flux-cap
40
+ cd flux-cap
41
+
42
+ # Install dependencies
43
+ bun install
44
+
45
+ # Run locally
46
+ bun run dev <command>
47
+ ```
48
+
49
+ ## πŸš€ Quick Start
50
+
51
+ ### 1. Initialize flux-cap in your project
52
+ ```bash
53
+ bun run dev init
54
+ ```
55
+ *Interactive setup will ask about your privacy preferences*
56
+
57
+ ### 2. Start capturing thoughts
58
+ ```bash
59
+ bun run dev dump "remember to add error handling to auth module"
60
+ bun run dev dump "bug in user validation - check line 42"
61
+ bun run dev dump "idea: add dark mode toggle"
62
+ ```
63
+
64
+ ### 3. Search your brain dumps
65
+ ```bash
66
+ # Search with a query
67
+ bun run dev search "auth"
68
+
69
+ # List recent dumps (no query)
70
+ bun run dev search
71
+ ```
72
+
73
+ ## πŸ“š Commands
74
+
75
+ | Command | Description | Example |
76
+ |---------|-------------|---------|
77
+ | `flux init` | Initialize flux-cap with privacy setup | `bun run dev init` |
78
+ | `flux dump <message...>` | Capture a brain dump | `bun run dev dump "fix the bug in auth.ts"` |
79
+ | `flux search [query...]` | Search brain dumps or list recent ones | `bun run dev search "authentication"` |
80
+ | `flux config <fields...>` | View or update configuration | `bun run dev config` |
81
+ | `flux reset` | Complete reset (deletes all data) | `bun run dev reset` |
82
+
83
+ ## βš™οΈ Configuration
84
+
85
+ flux-cap stores configuration in `.flux/config.json`. You can customize:
86
+
87
+ ### Privacy Settings
88
+ ```json
89
+ {
90
+ "privacy": {
91
+ "hideWorkingDir": false, // Hide file paths
92
+ "hideBranchName": false, // Hide git branch names
93
+ "hideUncommittedChanges": false // Hide git status
94
+ }
95
+ }
96
+ ```
97
+
98
+ ### Search Configuration
99
+ ```json
100
+ {
101
+ "search": {
102
+ "searchFields": ["message", "branch", "workingDir"],
103
+ "resultLimit": 10,
104
+ "fuseOptions": {
105
+ "threshold": 0.3, // 0.0 = exact match, 1.0 = match anything
106
+ "includeScore": true
107
+ }
108
+ }
109
+ }
110
+ ```
111
+
112
+ ### Other Options
113
+ ```json
114
+ {
115
+ "defaultFocusDuration": 1500, // 25 minutes in seconds
116
+ "todoKeywords": ["TODO", "FIXME", "BUG", "OPTIMIZE", "HACK"],
117
+ "sorted": true, // Sort dumps chronologically
118
+ "theme": "minimal"
119
+ }
120
+ ```
121
+
122
+ ## πŸ“ Data Structure
123
+
124
+ ```
125
+ .flux/
126
+ β”œβ”€β”€ config.json # Your configuration
127
+ β”œβ”€β”€ dumps/ # Brain dumps organized by month
128
+ β”‚ β”œβ”€β”€ 2026-02.json
129
+ β”‚ └── 2026-03.json
130
+ └── sessions/ # Future: Focus session tracking
131
+ ```
132
+
133
+ ### Brain Dump Format
134
+ ```json
135
+ {
136
+ "id": "019c5419-671b-7000-9600-5d9b4c563579",
137
+ "timestamp": "2026-02-12T23:04:36.891Z",
138
+ "message": "fix auth validation bug",
139
+ "workingDir": "/Users/you/project",
140
+ "branch": "feature/auth-fix",
141
+ "hasUncommittedChanges": true
142
+ }
143
+ ```
144
+
145
+ ## 🎯 Use Cases
146
+
147
+ ### Context Switching
148
+ ```bash
149
+ # Before switching tasks
150
+ flux dump "was working on user auth, next: add validation to login form"
151
+
152
+ # After interruption
153
+ flux search "auth" # Quickly find where you left off
154
+ ```
155
+
156
+ ### Bug Tracking
157
+ ```bash
158
+ flux dump "weird bug in payment flow - users can't checkout"
159
+ flux dump "bug seems related to session timeout"
160
+
161
+ # Later...
162
+ flux search "payment bug"
163
+ ```
164
+
165
+ ### Idea Capture
166
+ ```bash
167
+ flux dump "idea: add keyboard shortcuts to dashboard"
168
+ flux dump "maybe use React.memo for performance optimization"
169
+ ```
170
+
171
+ ## πŸ› οΈ Development
172
+
173
+ Built with:
174
+ - **Bun** - Fast JavaScript runtime
175
+ - **TypeScript** - Type safety
176
+ - **Commander.js** - CLI parsing
177
+ - **Fuse.js** - Fuzzy search
178
+
179
+ ### Project Structure
180
+ ```
181
+ src/
182
+ β”œβ”€β”€ commands/ # Command implementations
183
+ β”‚ β”œβ”€β”€ dump.command.ts
184
+ β”‚ β”œβ”€β”€ search.command.ts
185
+ β”‚ └── init.command.ts
186
+ β”œβ”€β”€ utils/ # Shared utilities
187
+ β”‚ β”œβ”€β”€ privacy.ts # Git integration
188
+ β”‚ β”œβ”€β”€ fuse.instance.ts # Search configuration
189
+ β”‚ └── lib.ts # File operations
190
+ └── types/ # TypeScript definitions
191
+ ```
192
+
193
+ ## πŸ—ΊοΈ Roadmap
194
+
195
+ ### Phase 2 (Coming Soon)
196
+ - [ ] ASCII Pomodoro timer with themes
197
+ - [ ] Visual focus mode display
198
+ - [ ] Theme rotation system
199
+
200
+ ### Phase 3 (Future)
201
+ - [ ] Advanced git context switching
202
+ - [ ] Session restoration
203
+ - [ ] Time tracking per context
204
+
205
+ ### Phase 4 (Maybe)
206
+ - [ ] AI-powered brain dump analysis
207
+ - [ ] Team collaboration features
208
+ - [ ] Cross-machine sync
209
+
210
+ ## 🀝 Contributing
211
+
212
+ This is currently a personal learning project, but feedback and suggestions are welcome!
213
+
214
+ ## πŸ“„ License
215
+
216
+ MIT
217
+
218
+ ---
219
+
220
+ **Built for developers who think fast, context-switch often, and never want to lose a good idea.** πŸš€
221
+ ```
222
+
223
+ This README showcases:
224
+ - βœ… Clear value proposition for ADHD developers
225
+ - βœ… All implemented features with examples
226
+ - βœ… Complete command reference
227
+ - βœ… Configuration documentation
228
+ - βœ… Privacy-first messaging
229
+ - βœ… Data structure transparency
230
+ - βœ… Real use cases
231
+ - βœ… Development info
232
+ - βœ… Future roadmap
233
+
234
+ **Ready to ship this for UAT?** The README positions flux-cap as a professional, thoughtful developer tool.