[tw] Re: Find and Replace in all tiddlers

2013-07-27 Thread Aquilai
Ah I missed the tooltip that said it was regex based. That's even more 
helpful thanks! It might be better if there was a message when the regex 
doesn't work. 

Just for completeness, I resolved my issue with the escape character \?. 

On Friday, July 26, 2013 5:00:51 PM UTC+1, Eric Shulman wrote:



 On Friday, July 26, 2013 6:30:19 AM UTC-7, Aquilai wrote:

 Can you confirm that the replace text function doesn't work with the 
 question mark ? symbol? Is there a workaround for this?

 TiddlerTweakerPlugin replace text function uses standard javascript 
 regular expression syntax for specifying the text *pattern* to match. 
  Here's a good reference for special characters in regular expressions:


 https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp

 note particularly the usage of ?:
 --
 Matches the preceding item 0 or 1 time.  For example, /e?le?/ matches the 
 'el' in angel and the 'le' in angle.  If used immediately after any of 
 the quantifiers *, +, ?, or {}, makes the quantifier non-greedy (matching 
 the minimum number of times), as opposed to the default, which is greedy 
 (matching the maximum number of times).
 --

 Perhaps you are using the ? incorrectly within your pattern.  Unlike the 
 use of  ? and * as 'wildcard symbols' in filenames, javascript regular 
 expressions use the . (dot) symbol to match a single wildcard 
 character.   You can make that character optional (0 or 1 instances) by 
 adding a ? following it (i.e., .?).  You can match any number of 
 characters (0 or more) by adding a * suffix following the dot (i.e, .*)

 enjoy,
 -e
 Eric Shulman
 TiddlyTools / ELS Design Studios

 HELP ME TO HELP YOU - MAKE A CONTRIBUTION TO MY TIP JAR...
http://www.TiddlyTools.com/#Donations

 Professional TiddlyWiki Consulting Services...
 Analysis, Design, and Custom Solutions:
http://www.TiddlyTools.com/#Contact


-- 
You received this message because you are subscribed to the Google Groups 
TiddlyWiki group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/groups/opt_out.




[tw] Re: Find and Replace in all tiddlers

2013-07-26 Thread Aquilai
Can you confirm that the replace text function doesn't work with the 
question mark ? symbol? Is there a workaround for this?

On Thursday, April 12, 2012 6:53:30 PM UTC+1, Eric Shulman wrote:

  for example i have links to the tiddler HardwareStore and to the 
  tiddler LokalFarmersMarket in a tiddlers which contains an Interview 
  about where People get their Plants from. Also i have somewhere some 
  tiddlers that are tagged with HardwareStore. 
  
  now i decide for example, that i dont want to have two tiddlers 
  LokalFarmersMarket and HardwareStore but that i only want to have one 
  Tiddler called Market. 
  
  so i need a find and replace option like it is in every editor that 
  doesn't care where in the tiddlywiki file the word should be replaced, 
  and just simply replace LokalFarmersMarket and HardwareStore into 
  Market everywhere. I am aware that this could destroy the tiddlywiki 
  System. 

 TiddlerTweakerPlugin can be used to change text in *all* tiddlers at 
 once.  Simply select all the tiddlers from the listbox in the 
 TiddlerTweaker control panel.  Then check the [x] replace text option, 
 enter your desired search text and the 'replace with' text, and press 
 the 'update' button. 

 Note that the [x]replace text function is only applied to the text 
 content of the tiddler.  To change tags, use the separate [x]tags 
 option in TiddlerTweaker.  First use the 'tags' selector (upper right 
 above the listbox) and enter a tag value to select all tiddlers with 
 that tag. Then, enable the [x]tags option and enter the old tag *and* 
 new tag into the input, using the special + and - prefix symbols. 
 For example, -HardwareStore +Market removes HardwareStore and adds 
 Market to all selected tiddlers. 

 Note also that, while TiddlerTweaker will change the *text* and/or 
 *tags* of the selected tiddlers, it will not *automatically* rename 
 tiddlers.  However, you can use TiddlerTweaker to quickly rename 
 individual tiddlers as well.  Simply select a single tiddler from the 
 listbox, check the [x]title option, enter a new title, and press 
 update. 

 enjoy, 
 -e 
 Eric Shulman 
 TiddlyTools / ELS Design Studios 

  
 WAS THIS ANSWER HELPFUL?  IF SO, PLEASE MAKE A DONATION 
http://www.TiddlyTools.com/#Donations 
 note: donations are directly used to pay for food, rent, 
 gas, net connection, etc., so please give generously and often! 

 Professional TiddlyWiki Consulting Services... 
 Analysis, Design, and Custom Solutions: 
http://www.TiddlyTools.com/#Contact 



-- 
You received this message because you are subscribed to the Google Groups 
TiddlyWiki group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to tiddlywiki+unsubscr...@googlegroups.com.
To post to this group, send email to tiddlywiki@googlegroups.com.
Visit this group at http://groups.google.com/group/tiddlywiki.
For more options, visit https://groups.google.com/groups/opt_out.