Eric,

This is nice an elegant. I tested it on Tiddlywiki.com and realised perhaps 
an option to also rename the tag tiddler as well, eg HelloThere

Thus the tiddlers so tagged rejoin there parent? 

Otherwise my solution of renaming an existing tag tiddler is safer?

Regards
Tony


On Sunday, June 7, 2020 at 2:02:18 PM UTC+10, Eric Shulman wrote:
>
> On Saturday, June 6, 2020 at 3:38:47 PM UTC-7, springer wrote:
>>
>> For future readers of this thread, there's also Alberto Molina's special 
>> solution, here:
>> https://groups.google.com/forum/#!topic/tiddlywiki/OCntQ79DuwM
>> which doesn't require creating a tiddler for the tag, and also is much 
>> lighter-weight than the very powerful TW-Commander.
>>
>
> Here's another solution:
> <$select tiddler="$:/temp/changetag/old" default="">
>    <option value="">select an existing tag...</option>
>    <$list 
> filter="[tags[]sort[]]"><option><<currentTiddler>></option></$list>
> </$select>
> <$edit-text tag="input" tiddler="$:/temp/changetag/new" default="" 
> placeholder="enter a new tag..." />
> <$button> change
>    <$list filter="[tag{$:/temp/changetag/old}]">
>       <$action-listops $tiddler=<<currentTiddler>> $field="tags" 
> $subfilter="-[{$:/temp/changetag/old}] [{$:/temp/changetag/new}]" />
>    </$list>
>    <$action-deletetiddler $tiddler="$:/temp/changetag/old" />
> </$button>
> <$button> reset
>    <$action-deletetiddler $filter="[prefix[$:/temp/changetag]]" />
> </$button><br>
> Change these tiddlers:<br>
> <$list filter="[tag{$:/temp/changetag/old}]"> <li><$link/></li> </$list>
>
> Notes:
> * The $select gives you a droplist of all current tags in the document 
> (plus a prompt text at the top of the droplist)
> * The selected tag is stored in $:/temp/changetag/old
> * The $edit-text lets you input a new tag name into $:/temp/changetag/new
> * The change $button loops over all tiddler matching the old tag and uses 
> $action-listops to remove the old tag and add the new tag
> * The change $button also resets the selection in the list of tags (since 
> the selected tag no longer exists in the document)
> * The reset $button clears both temp inputs
> * The $list that appear below the form controls shows you which tiddlers 
> will be re-tagged
>
> enjoy,
> -e
>
>
>

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/6084a1d3-04fe-4415-b038-3119ff396ea8o%40googlegroups.com.

Reply via email to