feat: enhance host resolution, filtering, and cache management
Release / release (push) Successful in 49s

- **Strategies**: Add resolver strategy input validation and parsing in setup wizard. Support comma-separated input with known strategy mapping.
- **Client**: Extend Search and SearchAll to include kind and tag filters. Add pagination for full cache refresh handling large datasets.
- **Cache**: Introduce `RecentlyUsed` and `MarkUsed`. Persist `LastUsed` timestamps for entries.
- **TUI**: Add recent hosts view, tag/kind filters, and inline editor for user/port override.
- **Tests**: Comprehensive unit tests for new features, including strategy validation, cache behavior, and client filtering.
- **Docs**: Update README with new TUI features and cache subcommands.
This commit is contained in:
Sebastian Unterschütz
2026-05-23 17:06:24 +02:00
parent cdf750081e
commit d127a3b957
10 changed files with 795 additions and 97 deletions
+7
View File
@@ -1,5 +1,12 @@
package netbox
// SearchOptions filters a Search or SearchAll query.
// Zero value means no filtering (return all kinds, no tag filter).
type SearchOptions struct {
Tag string // filter by tag slug; empty = no filter
Kind string // "device" | "vm" | "" (both)
}
// HostEntry is a unified model for both devices and virtual machines from NetBox.
type HostEntry struct {
ID int