* Allow stateless commands to be run without config/database
Fixes an issue where gen-completions fails trying to create a config
directory in restrained build environments/distribution.
* move non-db commands up to core subcommands
* re-add lost lines
* re-add lost lines
Co-authored-by: Conrad Ludgate <conrad.ludgate@truelayer.com>
* Batch input events and only query once they are finished
This simplifies the code a lot (no more bounded channel) and yields
the same performance improvement with scroll wheel spam while fixing copy/paste
* Clippy
* fmt
* Use blocking wait before emptying events channel
This was causing a busy loop
* Update query on filter mode change
* Adds the rpassword dependency
* Provides only a prompt based input for login and register with a hidden prompt for password
* Adds option based inputs for login and register commands
* Password can also be provided as an option
Co-authored-by: Satyarth <satyarth.sampath@gojek.com>
* Attempting to implement zsh-histdb import
Import compiles passes tests, but doesn't run b/c of async runtime.
zsh-histdb uses sqlite, and sqlx-rs is async, but import code is sync.
* More working on importing histdb
* Rewriting tests and using `Vec<u8>` instead of `String`
- Rewriting tests to eliminate depencency on local file system
- Using `Vec<u8>` for command strings instead of `String` to eliminate
the utf8 errors i was seeing previously. Seems to be working.
* Running fmt
Co-authored-by: Bradley Noyes <b@noyes.dev>
binding on "up" can conflict with the default fish keybindings as when
in tab-completion mode, you are supposed to be able to use arrow keys
to navigate the grid of suggestions, however pressing "up" will open
the tui instead.
This attempts to work around it by tracking when the user is probably in
a tab completion mode by setting a variable that we use to determine
whether to open atuin or perform the default fish up action
* stat command parsing is handled without subcommands
* Updates match clause based on PR review
Co-authored-by: Conrad Ludgate <oon@conradludgate.com>
* updates value returned by match based on PR review
* adds vscode to gitignore
* use an if statement instead of match
Co-authored-by: Satyarth <satyarth.sampath@gojek.com>
Co-authored-by: Conrad Ludgate <oon@conradludgate.com>
* Add history filters, and hotkey toggle
Switch between different search modes to narrow down the history you
want - global search for all history, host for all history from your
current machine, session for the current shell session, and directory
for the current directory
The default can be configured via `filter_mode`
* Update docs
* Add context
Resolve#189
We were throwing an OutOfRangeError. This occurs when you attempt to
convert to a duration, and your input is <0. A value in the future would
have done this. This is especially noticeable during DST...
* remove unused environment var loading entire history into an env var
* Add Alt+backspace and Ctrl+u keybinds for deleting by word and by line, respectively
* Add gen-completions subcommand for generating shell completions
* Update documentation about generating shell completions
* Include the shell completions in release tarball
* feat: allow credential input from stdin for registration
This changes the options for register to be optional. If arguments are
not given, the program will ask for them interactively.
* feat: allow credential input from stdin for login
* style: apply cargo fmt
* run shellcheck
* Update .github/workflows/shellcheck.yml
Co-authored-by: Conrad Ludgate <oon@conradludgate.com>
* shellcheck fixes in which i am highly confident
* shellcheck fixes in which I am less confident - not executing this is fine, right?
* SC2155
In src/shell/atuin.bash line 1:
export ATUIN_SESSION=$(atuin uuid)
^-----------^ SC2155: Declare and assign separately to avoid masking return values.
* shellcheck doesn't support zsh, per https://github.com/koalaman/shellcheck/wiki/SC1071
* yaml fix
* gotta checkout our code, too
* yaml fix
* action spelling
* exclude .zsh
* Shellcheck doesn't support zsh, per
https://github.com/koalaman/shellcheck/wiki/SC1071, and the ignore: param
in ludeeus/action-shellcheck only supports _directories_, not _files_.
So instead, we manually add any error the shellcheck step finds in the
file to the above line ...
* comment all the ignores
* Update src/shell/atuin.bash
Co-authored-by: Ellie Huxtable <ellie@elliehuxtable.com>
* new zsh plugin shellcheck errors
* new zsh plugin shellcheck errors, pt 2
Co-authored-by: Conrad Ludgate <oon@conradludgate.com>
Co-authored-by: Ellie Huxtable <ellie@elliehuxtable.com>