[Vimprobable-users] patch to open several bookmarked urls at once

Matto Fransen matto at matto.nl
Mon Aug 16 15:03:29 GMT 2010


On Mon, Aug 16, 2010 at 12:02:18PM +0200, Hannes Schüller wrote:
> I think the idea of tagging bookmarks is certainly good and useful.
> Batch opening doesn't seem to be a huge function, so I have no
> objections. What I would like to see is this, though:
> :bma tag1 tag2 tag2
> :bma tag4
> :bma
> ...should all work. I.e. the bookmark function should take an optional
> string argument writing everything after the first space into the
> bookmarks file as tags. Do you think you can do that?
I will try :)

> About the patch so far:
> > +     { "qt", search_tag,       {0} },
> Why :qt? Wouldn't 'q' be associated with quitting or quickmarks? I
> don't particularly object, but I'd really like to learn what prompted
> that decision :)
That is a q from quick and a t from tags :)
But like I wrote in my email, I didn't have much inspiration for a 
better command.

> >  		      k = strlen(tag);
> >		      if ( strncmp( tag, foundtag, k ) == 0 )
> Here, you don't actually make sure the strings match. All you check is
> that tag is a substring of foundtag since foundtag can be longer. Is
> that intentional?

Nope, that was not the intention, just trying to prevents complaints
by using strcmp. I could first check to see if both tag and foundtag
are within a reasonable limit and then we can strcmp :)

I'll look into that.

Thanks for your feedback!


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://vimprobable.org/pipermail/vimprobable-users/attachments/20100816/33b3ca5b/attachment.bin>

More information about the Vimprobable-users mailing list