Skip to content

0.3.0 — --last-used, --hourly, multi-file input, and timestamp parsing upgrade - #6

Merged
ultraelectronica merged 35 commits into
masterfrom
versionF
Aug 18, 2026
Merged

ultraelectronica merged 35 commits into
masterfrom
versionF

Conversation

@ultraelectronica

Copy link
Copy Markdown
Owner

Description:

Shellist 0.3.0 adds several roadmap items and parser improvements:

  • --last-used — show last-run date per command (table output, needs timestamps)
  • --hourly — hour-of-day usage distribution, UTC-based (needs timestamps)
  • Multi-file input — --path accepts comma-separated paths (and - for stdin)
  • --no-strip — opt out of stripping leading sudo / VAR=val prefixes
  • --collapse — merge adjacent identical lines before counting
  • Relative dates — --since/--until accept 7d/2w/3m in addition to YYYY-MM-DD; --grep now works with --trend
  • --version flag
  • Parser fixes — bash HISTTIMEFORMAT timestamp lines, fish escape-sequence unescaping, case-insensitive grep, stricter date validation (rejects nonexistent calendar dates)

Remove unused `default_history_path_for` export and add
`BashHistoryParser` type alias for naming consistency. Implement
`parse_with_detected` function that detects shell format and dispatches
to the appropriate parser.
Update `default_history_path` to return `Option<PathBuf>` instead of
panicking when `HOME` is unset.  Change `home_dir` to return
`Option<PathBuf>` accordingly.

Delegate zsh extended history detection to the parser module.
Strips leading `sudo` and `VAR=value` environment assignments from
command
strings, returning the remaining command. Useful for parsing shell
history
where commands may be prefixed with privilege escalation or environment
context.
- Strip sudo/env prefixes from commands by default (disable with
  --no-strip)
- Add --collapse to merge adjacent duplicate entries before counting
- Support relative dates (Nd/Nw/Nm) in --since/--until arguments
- Add --version flag
- Fix trend mode to apply grep filter before bucketing
Add multi-file support (comma-separated paths, repeatable). Add --hourly
flag
for hour-of-day distribution. Add --last-used column to table output.
Each
file's shell format is detected separately, enabling zsh+fish merges.
@ultraelectronica ultraelectronica self-assigned this Aug 18, 2026
# Conflicts:
#	src/aggregators/command_counter.rs
#	src/completions.rs
#	src/date.rs
#	src/lib.rs
#	src/main.rs
#	src/man.rs
#	src/models/history_entry.rs
#	src/output/table.rs
@ultraelectronica
ultraelectronica merged commit b0ebbc9 into master Aug 18, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant