Add demo recording tools (asciinema, vhs) and release tooling
(cargo-dist) to nativeBuildInputs. Include a cargo-dist wrapper so
`cargo dist` works as a subcommand. Add scripts/record-demo.sh for
consistent asciinema cast recording at 100x30.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
40-row CSV with obviously-fake sales data (fictional companies like
Acme Corp, Wonka Industries, Cyberdyne Systems). demo.improv generated
via headless import with Profit formula and a default view showing
Region+Product on rows, Date_Month+Measure on columns. Added the
import command to the README quick-start section.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add dedicated sections for the data model (formula examples), views and
axes (tile mode, records mode, drill-down), the .improv file format
(annotated example), import wizard and headless scripting, and the
command/effect architecture. Link docs/design-notes.md from the "Why"
section. Update build instructions to use `nix build .`.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Audited SPEC.md against code — mostly accurate but redundant with
repo-map.md and design-principles.md. Minor drift in storage internals,
wizard step count, and mode representation. Salvaged product vision and
non-goals into docs/design-notes.md with staleness disclaimer.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add CL/SQL-style symbol quoting using pipe delimiters for formula
identifiers. This allows category and item names that collide with
keywords (WHERE, SUM, IF, etc.) or contain special characters
(parens, operators, spaces) to be used unambiguously in formulas:
|WHERE| + |Revenue (USD)|
SUM(|Net Revenue| WHERE |Region Name| = |East Coast|)
Pipes produce Token::Ident (same as bare identifiers), so they work
everywhere: expressions, aggregates, WHERE clauses. Double-quoted
strings remain Token::Str for backward compatibility.
Also updates split_where and parse_where to skip/strip pipe delimiters.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add repository, homepage, readme, keywords, and categories fields.
Update description to match project vision. Use GitHub URLs for
public discoverability.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add repository, homepage, readme, keywords, and categories fields.
Update description to match project vision.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add virtual category boundary rule: use regular_category_names() for
user-facing logic, never expose _Index/_Dim
- Document formula tokenizer keyword-aware identifier breaking
- Update repo-map test counts (356 → 510) and add regular_category_names
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The tokenizer already broke multi-word identifiers when the NEXT word
was a keyword, but not when the identifier collected SO FAR was a
keyword. This meant "WHERE Region" was merged into one token when
tokenizing "SUM(Revenue WHERE Region = East)".
Now the tokenizer also checks if the identifier built up to the current
space IS a keyword (WHERE, SUM, AVG, MIN, MAX, COUNT, IF), which
correctly produces separate tokens for "Revenue", "WHERE", "Region".
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Updates `CommitFormula` and `ImportPipeline` to use
`regular_category_names` instead of `category_names` . This ensures that
these components do not target or default to virtual categories (_Index,
_Dim) when no regular categories are present.
Includes updated tests for `CommitFormula` to verify it correctly handles
cases with no regular categories.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Updates `Model` to include `regular_category_names` , which returns
category names excluding virtual categories (_Index, _Dim). This allows
other parts of the application to distinguish between user-defined
categories and system-internal ones.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
The tokenizer was greedily consuming spaces and potentially merging
identifiers with subsequent keywords. This change improves the tokenizer
by:
- Peeking ahead past spaces to find the next word/token.
- Breaking the identifier if the next word is a known keyword (WHERE, SUM,
AVG, MIN, MAX, COUNT, IF).
- Adding support for more delimiter characters (<, >, =, !, ").
This fixes a regression where "Revenue WHERE" was treated as a single
identifier instead of an identifier followed by a WHERE clause.
Includes a new regression test for inline WHERE filters in aggregate
functions.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Add unit tests for ImportWizard and ImportPipeline, covering:
- Wizard step transitions
- Proposal and formula editing
- Date configuration
- Edge cases for building the data model
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Add a comprehensive suite of unit tests for the formula parser, covering:
- Aggregate functions
- WHERE clauses
- Comparison operators
- Arithmetic operations
- Various error handling scenarios
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Add unit tests for various commands including PasteCell, TransposeAxes,
ViewNavigate, and MovePanelCursor to ensure correct command execution and
state changes.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Improve feedback for axis operations:
- `CycleAxisAtCursor` : Now provides a status message if no category is at
the cursor.
- `TileAxisOp` :
- Now provides a status message showing the new axis (e.g., "Category →
Row").
- No longer automatically switches to `AppMode::Normal` , allowing for
multiple consecutive adjustments.
- Provides a status message if no category is at the cursor.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Add unit tests for model precision and category tree rendering:
- `src/model/types.rs` : Added `formula_chain_preserves_full_precision` to
ensure formulas use full `f64` precision for calculations, even when
display is rounded.
- `src/ui/cat_tree.rs` : Added comprehensive tests for `build_cat_tree` ,
covering empty models (virtual categories), expanded/collapsed states,
and item rendering.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Improve number formatting and add comprehensive tests:
- Implemented `round_half_away` to provide more intuitive rounding (e.g.,
2.5 -> 3, -2.5 -> -3).
- Updated `format_f64` to use this rounding logic.
- Added extensive unit tests for `parse_number_format` and `format_f64` ,
covering various edge cases and rounding behaviors.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Improve UI rendering and feedback:
- `src/draw.rs` :
- Automatically enter Help mode if the model is empty.
- Render the `HelpWidget` with the current help page.
- Render the `WhichKeyWidget` when a transient keymap is active.
- `src/ui/tile_bar.rs` : Use more descriptive labels for axes (e.g., "Row",
"Col", "Pag").
- `src/ui/view_panel.rs` :
- Include an axis summary (e.g., "R:Region C:Product") next to view
names.
- Refactor `ViewContent` to hold a reference to the `Model` .
- `src/ui/effect.rs` : Add error feedback to `AddItem` , `AddItemInGroup` ,
and `AddFormula` when operations fail.
- `src/ui/help.rs` : Refactor `HelpWidget` into a multi-page system.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Update keymaps to allow entering command mode via ':' in various panels and
add help page navigation.
- Added ':' command binding to Help, FormulaPanel, CategoryPanel,
ViewPanel, and TileSelect modes.
- Added navigation bindings (Right/Left, l/h, n/p, Tab/BackTab) to the Help
keymap.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Implement `WhichKey` popup to show available command completions.
- Added `format_key_label` to convert `KeyCode` to human-readable strings.
- Added `binding_hints` to `Keymap` to extract available commands for a
given prefix.
- Added `src/ui/which_key.rs` for the widget implementation.
- Updated `src/ui/mod.rs` to export the new module.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Implement help page navigation with `help-page-next` and `help-page-prev`
commands.
- Added `HelpPageNextCmd` and `HelpPagePrevCmd` to `src/command/cmd.rs` .
- Registered help navigation commands in `CmdRegistry` .
- Updated `HelpCmd` to initialize the help page.
- Added unit tests for help navigation in `src/ui/app.rs` .
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Implement `add-items` command to allow adding multiple items to a category
at once.
- Added `AddItemsCmd` to `src/command/cmd.rs` .
- Registered `add-items` in `CmdRegistry` .
- Added unit tests for `add-items` in `src/command/parse.rs` .
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Implement command aliasing in CmdRegistry and update command parsing to
resolve aliases.
- Added `aliases` field to `CmdRegistry` .
- Added `alias()` method to register short names.
- Added `resolve()` method to map aliases to canonical names.
- Updated `parse()` and `interactive()` to use `resolve()` .
- Added unit tests for alias resolution in `src/command/parse.rs` .
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Add new context files to assist with repository navigation and design
consistency:
- context/repo-map.md: A roadmap for the repository.
- context/design-principles.md: Guidelines for maintaining repository
consistency.
Update CLAUDE.md to include instructions on using the new context files.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Move the main function from the bottom of the file to the top, after
imports.
This improves code readability by placing the entry point closer to the top
of the file.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Replace manual dynamic dispatch using Box <dyn Runnable> with enum_dispatch
for improved performance and cleaner code.
Add a new Open command to allow opening the TUI as the default behavior
when no subcommand is provided.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Refactor the CLI command structure by moving subcommand arguments into
dedicated structs (ImportArgs, CmdArgs, and ScriptArgs).
Introduce a Runnable trait to allow for polymorphic command execution,
replacing the large match statement in the main function with a more
scalable approach.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (unsloth/gemma-4-26B-A4B-it-GGUF:UD-Q5_K_XL)
Split multi-line let statements in command tests into separate lines.
Remove unnecessary commas and inline vec! macro. Clean up test code
formatting for readability. No functional changes, only style improvements.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)
Add footer_height method to PanelContent trait with default 0. Implement
footer_height in FormulaContent to return 1 when in FormulaEdit mode.
Update Panel::render to subtract footer height from item height. This
enables optional footers in panels.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)
Refactor AppMode to use MinibufferConfig for all text-entry modes. Update
command implementations to use new mode constructors. Introduce
PanelContent trait and replace panel structs with content types. Adjust
rendering to use Panel::new and minibuffer configuration. Update imports
and add MinibufferConfig struct. No functional changes; all behavior
preserved.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)
Add a `changes_mode` method to the `Effect` trait with a default implementation
returning `false` . Implement this method for the `ChangeMode` effect to return
`true` . Update the command execution logic to use `e.changes_mode()` instead of
string matching on formatted output. Adjust the corresponding test to assert the
presence of a mode‑changing effect directly via the new method, removing the
temporary debug string.
This change introduces a clear, typed way to detect mode‑changing effects,
improving readability and reducing reliance on string inspection.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)
Expose CmdRegistry via KeymapSet registry method.
Update Z keybinding to use SaveAndQuit command.
Pass registry to App's CmdContext construction.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)
Update CmdContext to include registry reference.
Adjust make_ctx function signature to accept registry.
Update all tests to pass the default registry.
Ensure test contexts are constructed with registry.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)
Add new command structs for quitting and command execution.
Introduce Quit and SaveAndQuit commands with dirty checks.
Add ExecuteCommand for handling ':' input.
Define effect_cmd for SetFormatCmd, ImportCmd, ExportCmd, WriteCmd, and HelpCmd.
Register the new commands in the default command registry.
Fix a buggy mode reset check that used Debug string matching.
Co-Authored-By: fiddlerwoaroof/git-smart-commit (bartowski/nvidia_Nemotron-Cascade-2-30B-A3B-GGUF)