bibtool icon indicating copy to clipboard operation
bibtool copied to clipboard

selects with AND logic

Open Marwe opened this issue 9 years ago • 3 comments

Is there any possibility to have complex select statement combinations? I am currently missing something like

((select {keywords "firstkeyword"} AND select {keywords "secondkeyword"}) OR select{keyword "alwaysselected"})

I can currently only achieve this with pipes on the commandline, combining the output of consecutive invocations of bibtool. A regex might be a solution for OR cases in common field definitions.

AND/OR(currently default) and maybe XOR would be all logic operators needed (NOT selectors like existing with select.non should also work).

Thank you for the great tool!

Marwe avatar Oct 11 '15 20:10 Marwe

Many years ago I had started to build something in this direction. Unfortunately I lost the code when the computer crashed back then. I havn't started a new approach since then. But I put it on my list. Maybe the goal can be achieved without too much effort.

ge-ne avatar Oct 12 '15 15:10 ge-ne

I have started an experiment for this. In this course I started to reconstruct some code which I had lost a few years back. It is a complete rewrite of the resoruce language. This should provide more power and expressiveness to BibTool. Unfortunately this is not just a small change but requires some work...

ge-ne avatar Nov 04 '15 19:11 ge-ne

Sounds like a larger change indeed. Thank you for looking into it and making bibtool even better as it is already (in my opinion it is already the most advanced tool for bibtex manipulation).

Marwe avatar Nov 05 '15 08:11 Marwe