[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: How to match last word in quotes in a sentence in Lua
- From: Joe Eaves <jinux@...>
- Date: Mon, 14 Oct 2013 10:46:39 +0100
On 14 October 2013 10:22, Igor <igor.iptv@gmail.com> wrote:
> How to match last quoted word in a sentence (or first in quotes from end)
> and print it without quotes?
This works for me:
thing:match("\"[a-zA-Z0-9]+\".*(.*\"[a-zA-Z0-9]+\").*$")
It prints *with* the quote marks, but you should be able to strip
those off easily enough.
Joe
--
:wq!