Very cool! @KirillR and I have been thinking about something like this wrt org-roam-ui. Do you think this could somehow:
Do queries like: have tag X and be linked to files/nodes with tag Y?
Eventually be combined with org-ql like queries? So you could do something like: show all nodes with tag X and Deadline Y? This could probably already be done in here, since org-roam stores all org properties, but there are probably things org-ql can look for that arenât stored in the org-roam-db
It uses org-ql like queries. Search string to sexp conversion code is from org-ql. Like org-ql, you can define custom search types.
Both features you propose are possible. You would need to define a search type and appropriate transform and stringify form for it.
Transfrom converts the search type into a searchable entity. For example, the search term tag:tag1,tag2 is transformed to
I have upgraded to org roam search to support org roam v2.
now supports out of the box filtering by titles, tags, olp, level properties of nodes.
sorting is also implemented but not at the prompt level. Users will need to write a sorting clauses compatible with order-by sql clause.
not yet.
However, It is straightforward to implement dest: and source: . org-roam-url already does the latter.
the issue is what type of interface to use. I have made the following issue to track the feature. feel free to discuss here or there.
Yes. I currently have an integration between org-roam-search and delve.
My current workflow is search stuff with org-roam-search. Display results in a persistent fashion using delve-show which works like embark-export and can shuttle query string back and forth org-roam-search. And find nodes linking to urls from the browser using org-roam-url. I see that org-roam-ui and delve are now intergrated.
Currently filtering and sorting are conducted within the sql search. if view tables are merged into org-roam, I envision filtering and sorting within emacs will become viable.
One of these days I will try to place it on melpa. To quickly try it copy paste code in https://github.com/natask/sexp-string/blob/master/sexp-string.el and https://github.com/natask/org-roam-search/blob/master/org-roam-search.el into an empty buffer and run eval-buffer. After that read the readme on https://github.com/natask/org-roam-search to see how to use it.
To have it load with emacs it depends on which emacs distribution you are using. Follow the tutorials for the one you use. the core github repos to include are ânatask/org-roam-searchâ and ânatask/sexp-stringâ.
If you are on doom emacs, place the following code in packages.el in ~/.doom.d and run doom upgrade
I wanted to give it a try right away, but I get an error message saying that delve-show is missing. This happens both when copying and evaluating the contents of the two files you pointed to and when adding your snippets to my Doom config.
I checked your GitHub repo, but only found delve, no delve-show.
same here, thought i made some mistake. probably i list of dependancies i need to have installed already? i use vanilla emacs with very few packages installed so far. and everything is currently installed using package.el
sorry guys, I forgot to include delve-show. It would be easiest to remove the line (require delve-show) from org-roam-search. delve-show is not critical for the core function of this package. I use it to export search results into a delve buffer, which is a buffer that is aware of org roam constructs, so that I can interact with multiple search results with ease.
I have updated the read me to include quick experimentation and installation guide.
@savnk you sir, are a mensch! Thank you so much, but I think I am too new, to be doing this
Will return when I am a bit more experienced with installing stuff in emacs
Right now when I took your advice and put it all in a buffer and removed delve, and then ran org-roam-search-node-find or file-find then I get a
concat: Symbolâs function definition is void: s-downcase
and i donât want to trouble you further without me knowing what I am doing wrong
Iâm most excited about the ability to search for nodes with specific (sets of) backlinks.
I gave it a shot but couldnât get it to work properly.
For example, which query would I use to get a list of all nodes linking to the nodes âfooâ AND âbarâ? I get (only) false positives when I use source:foo or destination:foo.
s-downcase is a function within package called s.
install s from melpa. you may also need to install peg and dash from melpa. (use package-install command to install these).
like @wuqui said, starting out with doom emacs or in general with another distribution is wise because it comes with majority of the things you will need preinstalled. I started out with spacemacs and switch to doom because I