Code Monkey home page Code Monkey logo

Comments (2)

conradludgate avatar conradludgate commented on September 27, 2024

Some inspiration

from atuin.

ellie avatar ellie commented on September 27, 2024

Sorry, I've taken a while to get to this one. I also hate saying no to all of this because it sounds really fun ๐Ÿ˜ญ

Much as queries like you propose sound really cool, I definitely don't want to be adding a DSL (or similar) to Atuin. That's complexity that's totally not needed + I think would cause more issues in the long run.

I think most of the current issues we have with lack of expressiveness can be solved via implementing two things

  1. Allow multiple query flags (so atuin search --exit 0 --exit 1 --cwd $HOME --cwd . etc etc)
  2. Allowing SQL searches. These could be automatically prefixed with select * from history to make life easier

And then there could be a keybinding in the interactive mode to replace the text box with the filter editor.

I'd rather keep the keybindings fairly minimal. Something like Ctrl-r to switch between "search global", "search dir", "search session" would be nice.

We could have a flag + config for searching with SQL, which can then be overridden per-directory in a similar method as proposed here: #116 (comment). We should also encourage users to add their own keybindings - there's really nothing to stop people from adding another binding to search via some other filter, and arguably that belongs in the shell anyway.

99% of the time I don't think people will be wanting to run particularly advanced queries

One of the things I'd like to keep with Atuin is that people don't spend very long in the TUI. It should be quick to open, quick to find what you want, and quick to close - composing queries in it run counter to that.

Also... Tantivy is lovely and it would be super cool to include it. It would make it very easy to boost results by directory/session/whatever. However, we currently massively underutilize SQLite and I think we can get the same sorts of behaviour with some smarter search queries

from atuin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.