basic documentation

This commit is contained in:
anon
2024-08-16 16:42:49 +02:00
parent 7fe923bf8c
commit d14dd4dde9
3 changed files with 96 additions and 2 deletions

32
README.md Normal file

@ -0,0 +1,32 @@
# Histui
> TUI for your Bash history
## Demo
![placeholder](placeholder)
Histui that simply provides a fast TUI for your history.
It does not provide favourites ([alternative solution](placeholder)),
it does not attempt to manage your dotfiles
([alternative solution](https://www.gnu.org/software/stow/))
and it sure as hell does not replace your history storage while continuously syncing to a server
(no recommendations; please don't do that).
Histui fulfills its UNIX-y purpose and fuck-all else.
## Documentation
For usage details consult the [manual](documentation/histui.1.md).
## Installation
After copying the project and cd-ing to it's root,
```
make
```
should yield you a `histui` executable.
Compile errors on Linux are a symptom of missing requirements.
### Requirements to compile
+ C compiler
+ Bison parser generator
+ ncurses C library
+ sqlite3 C library
+ readline C library
+ (optional for man page) kramdown-man

@ -1,5 +1,3 @@
+ scroll flashes
+ technical dept in tui.cpp -
+ resizing
+ man page
+ readme

64
documentation/histui.1.md Normal file

@ -0,0 +1,64 @@
# Histui 1 manual
## DESCRIPTION
*Histui* is an interactive terminal interface for history entries.
It integrates with bash.
Do note that it does not replace the original history management.
## SYNOPSIS
**histui** [ *GLOBAL-OPTIONS* ] *VERB* [ *OPTIONS*+ ]
--version
: print version and quit
--help
: print help and quit
### enable
Dump a Bash script to stdout which is meant to be sourced from a bashrc.
### tui
Start the interactive interface.
--execute
: do not copy the selected entry to the Bash cli, but execute it upon selection.
*NOTE:* this requires TIOCSTI support from the terminal.
--fuzzy
: make the input be considered a fuzzy search.
Fuzzy searching should not be noticeably slower than regular searches,
but significantly, more convenient.
In contrast,
the default behaviour is to emulate the built in history search of Readline.
*NOTE:* In the current implementation this
--caseless
: ignore letter case in searches.
--group
: group equal commands together, in effect only showing the most recent invocation.
## Controls
`UP`
`DOWN`
`CTRL + j`
`CTRL + K`
: scroll the entry cursor by one
`PAGEUP`
`PAGEDOWN`
`CTRL + u`
`CTRL + d`
: scroll the entry cursor by half a screen
`ENTER`
: select the entry under the cursor, making histui terminate and returning the entry
`CTRL + q`
: like ENTER, but not affected by --execute
`DEFAULT`
: edit the query line
[//]: # (@BAKE kramdown-man $@ @STOP)