Lee composed on 2017-05-26 14:10 (UTC-0400):

> Felix wrote:

>> Fresh export with all set as you have except autoExport still has them all,
>> saved html file same size as last time. :-(

> Not really surprising - I think those settings just prevent icons from
> creeping into your bookmarks.

> You're a linux user, so you have vi - correct?

> Try this - hopefully it's just a one-time thing after you have all the
> icon stuph turned off:
> - export your bookmarks
> - exit seamonkey
> - copy the bookmarks.html file somewhere safe
> vi bookmarks.html
> :1,$ s/ ICON_URI="[^"]*"//
> :1,$ s/ ICON="data:[^"]*"//
> :wq
> - start seamonkey
> - delete all your bookmarks
> - import your edited bookmarks.html file

> I found an old bookmarks file in my backups and it had two types of
> icon references:
>  ICON_URI="http://whatever";
> and
>  ICON="data:image/png;base64,whatever"

> I don't remember if vi pattern matching is greedy or no, so instead of
> matching on
>  ".*" which could match way more than you want, match on
>  "[^"]*"
> which matches everything up to a "

> I'm on windoze & used the windows version of vim - ymmv

Thanks much! :-D I'm close to worthless working with wildcards and special
characters, but you enabled me to come up with this mini-script:

        sed 's/ ICON_URI="[^"]*"//g' $1 > $2
        sed 's/ ICON="data:[^"]*"//g' $2 > $3

The result was a 32.6% total reduction, from 787,654 to 531,157. The
intermediary step size was 759,359, -3.6%.

Your reply arrived when I was almost done doing it partially via script,
partially via text editor, starting with:

        sed 's/ ICON_URI=/\n ICON_URI=/g' $1 >> $2

That put each data item along with a relatively short appending string on a new
line, enabling me to quickly goto each such line, use END then cursor left to >,
hit enter, Ctrl-Y, then BS to rejoin the useful pieces of the DT item. I don't
know how long I spent, but I proceeded to finish before trying your method to
see what the difference might come out to. Mine was 526,235, 33.2% reduction,
but I took the liberty of deleting at least one duplicate DT in that process.

Deleting bookmarks then importing remains todo. I have multiple other profiles,
more than one of which need them imported too. I did already import into one FF
ESR 45 profile without doing any deletes first, via
user_pref("browser.places.importBookmarksHTML", true); in user.js. As both FF &
SM have done in the past, Recently Bookmarked and Recent Tags folders got
duplicated.
-- 
"The wise are known for their understanding, and pleasant
words are persuasive." Proverbs 16:21 (New Living Translation)

 Team OS/2 ** Reg. Linux User #211409 ** a11y rocks!

Felix Miata  ***  http://fm.no-ip.com/
_______________________________________________
support-seamonkey mailing list
[email protected]
https://lists.mozilla.org/listinfo/support-seamonkey

Reply via email to