Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 08-20-2014, 12:59 PM   #1
portersprings
Junior Member
portersprings began at the beginning.
 
Posts: 4
Karma: 10
Join Date: Aug 2014
Device: various
Mass Find and Replace

I am Sigil Newbie.

I am looking for a way to don mass find and replace of simple patterns like Find "dog" Replace "cat"

I am now doing this via the Spellcheck process but I am having to do it over and over.

Potentially I will have f&r lists containing 100s of items that I will want to run over 100s of sigl content pages.

What are good ways to do this?

I see Saved Search tool but I can't figure out how it works from the documentation available.

As I said, I am currently doing this via Spellcheck. Is there some way to "save" spellcheck conversions and then rerun them later?

Thanks in advance for any light that you can shed on this matter.
portersprings is offline   Reply With Quote
Old 08-20-2014, 01:11 PM   #2
mrmikel
Color me gone
mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.
 
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
From Search, use the find and replace function and choose replace all, if I am understanding what you want.

BEWARE!!! BACK UP YOUR DOCUMENT FIRST! Replace all can not be undone in Sigil.

After entering your search criteria, right click to save the search. Save search also allows to load saved searches.

Last edited by mrmikel; 08-20-2014 at 01:15 PM.
mrmikel is offline   Reply With Quote
Advert
Old 08-20-2014, 01:49 PM   #3
Toxaris
Wizard
Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.Toxaris ought to be getting tired of karma fortunes by now.
 
Toxaris's Avatar
 
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
In the saved searches window you can also group various searches. If you then select the folder and say replace all, all actions in the folder will be executed in order.
Toxaris is offline   Reply With Quote
Old 08-20-2014, 01:50 PM   #4
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,031
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
newbies to S&R should stay far away from Replace all's

There is an art to writing search terms that ONLY catch precisely what you want.
Code:
F: \scat\s
R: dog
which won't get catalog, catastrophe...

Extra care is needed to not modify the same term OUTSIDE the <body> block
theducks is online now   Reply With Quote
Old 08-20-2014, 01:59 PM   #5
mrmikel
Color me gone
mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.
 
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
I had a time recently when I wanted to capitalize all the instances of ATIS, a WWII agency. I also got sATISfaction as well!
mrmikel is offline   Reply With Quote
Advert
Old 08-20-2014, 05:57 PM   #6
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,306
Karma: 13057279
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by theducks View Post
newbies to S&R should stay far away from Replace all's

There is an art to writing search terms that ONLY catch precisely what you want.
Code:
F: \scat\s
R: dog
which won't get catalog, catastrophe...

Extra care is needed to not modify the same term OUTSIDE the <body> block
You wouldn't want "\s" in this case, "\s" matches any Whitespace Character. This on its face sounds reasonable if you want to catch a single word.... although it only catches " cat " with a space before+after.

You would want to use a Word Boundary, which is "\b". More information on it can be found here:

http://www.regular-expressions.info/wordboundaries.html

This would be a more accurate Regex:

Code:
F: \bcat\b
R: dog
Using \s would fail if you had these examples where no space is before AND after the word "cat":

Quote:
He kept on chanting, "cat jumped over the moon!"
"This was the cat's saucer."
He pushed the cat.
Quote:
Originally Posted by mrmikel View Post
I had a time recently when I wanted to capitalize all the instances of ATIS, a WWII agency. I also got sATISfaction as well!
Same with this case, you would want:

Code:
F: \batis\b
R: ATIS
I also second everyone saying BACK UP FIRST. And I would recommend against doing a Replace All, make sure that you are Replacing these one-by-one, and just double-checking to see that everything is working as you want it. It is very easy to make a simple mistake in a Regex and really mangle your document.

Last edited by Tex2002ans; 08-20-2014 at 06:06 PM.
Tex2002ans is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Find/Replace ? Otter Calibre 2 10-08-2012 08:48 PM
Find Replace unrulyguides Sigil 5 02-17-2012 08:38 PM
Find/Replace Won't Find Rand Brittain Sigil 7 09-24-2011 04:35 AM
Find / replace bremler Sigil 6 12-17-2010 03:26 PM
Using Find/Replace with BD Otter Sony Reader 7 02-28-2009 01:49 PM


All times are GMT -4. The time now is 11:16 PM.


MobileRead.com is a privately owned, operated and funded community.