← Back to team overview

calibre-devs team mailing list archive

Search and replace save/load mechanism

 

Hi,
it took me some time (quite few thing to think of) but ive manage to
finish search and replace query save/load.

Its very simple and straight forward - just load/save/remove, json and
dict based mechanism.

Please feel free to comment.

>On Mon, Jan 17, 2011 at 4:41 PM, Kovid Goyal <kovid@xxxxxxxxxxxxxx> wrote:
> Sure having a history for the regexps is a good idea.
>
> Kovid.
>
> On Mon, Jan 17, 2011 at 09:11:05AM +0000, Bartosz Szatkowski wrote:
>> Hi,
>> I know about search and replace, but creating regexp each time i have
>> to do this is not really convenient :) I had this problem (messy
>> authors) several times now and some of my friends has it too, so I
>> thought that maybe other people too :).
>>
>> I understate why You dont wont to expand UI in "ordinary" single and
>> bulk metadata, but maybe adding something like "save regexp"/"load
>> regexp" for search & replace would be a good idea? If so please let me
>> know i would do it :)
>>
>> On Sun, Jan 16, 2011 at 11:38 PM, Kovid Goyal <kovid@xxxxxxxxxxxxxx> wrote:
>> > Hi,
>> >
>> > Thanks for the patch. However, you can achieve this cleanup and many others already by using the Search and replace facility in the Bulk metadata edit dialog.
>> >
>> > See http://calibre-ebook.com/user_manual/metadata.html#search-and-replace
>> >
>> > Kovid.
>> >
>> > On Sun, Jan 16, 2011 at 10:28:09PM +0000, Bartosz Szatkowski wrote:
>> >> Hi,
>> >> i had lot of books with flipped author field, in format <author
>> >> lastname>, <author names> eg Salvatore, R. A. so all ebook collection
>> >> was in mess (books were sorted by author name not last name).
>> >> I wrote mechanism to clean name Salvatore, R.A -> R. A. Salvatore, for
>> >> now its don't modify multiple author fields and other "messy" ones (so
>> >> its more or less safe)
>> >>
>> >> I am not sure about proposed UI, please let me know if i have to change it.
>> >> If You consider my changes useful or have some suggestions please let
>> >> me know too.
>> >> Im going to work on more sophisticated cleaning mechanism (eg multiple
>> >> authors handling) and "auto author sort" in the future.
>> >>
>> >> --
>> >> Pozdrowienia,
>> >> bulislaw@xxxxxxxxx
>> >>
>> >>
>> >>
>> >
>> >
>> >> _______________________________________________
>> >> Mailing list: https://launchpad.net/~calibre-devs
>> >> Post to     : calibre-devs@xxxxxxxxxxxxxxxxxxx
>> >> Unsubscribe : https://launchpad.net/~calibre-devs
>> >> More help   : https://help.launchpad.net/ListHelp
>> >>
>> >>
>> >> !DSPAM:3,4d33710c10146619492854!
>> >
>> >
>> > --
>> > _____________________________________
>> >
>> > Dr. Kovid Goyal
>> > http://www.kovidgoyal.net
>> > http://calibre-ebook.com
>> > _____________________________________
>> >
>> > _______________________________________________
>> > Mailing list: https://launchpad.net/~calibre-devs
>> > Post to     : calibre-devs@xxxxxxxxxxxxxxxxxxx
>> > Unsubscribe : https://launchpad.net/~calibre-devs
>> > More help   : https://help.launchpad.net/ListHelp
>> >
>> >
>>
>>
>>
>> --
>> Pozdrowienia,
>> bulislaw@xxxxxxxxx
>>
>> !DSPAM:3,4d3407ad10141792913626!
>>
>>
>
> --
> _____________________________________
>
> Dr. Kovid Goyal
> http://www.kovidgoyal.net
> http://calibre-ebook.com
> _____________________________________
>




-- 
Pozdrowienia,
bulislaw@xxxxxxxxx

Attachment: add_s_r_save_load.patch
Description: Binary data