lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: notes regex expression


From: Gregrs
Subject: Re: notes regex expression
Date: Wed, 30 Aug 2017 21:58:52 +0100
User-agent: Mutt/1.8.3 (2017-05-23)

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Hi Gianmaria,

On Tue, Aug 29, 2017 at 06:51:26PM +0200, Gianmaria Lari wrote:

>Does anybody knows where I can find any regex expression to match 
>lilypond notes and chords?

The below expression (minus the quotation marks) seems to work for notes 
and chords without any articulation etc. attached. I've used Vim regex 
syntax so \@<= is a positive lookbehind to match the space before it and 
address@hidden is a positive lookahead to match the space before it. It also 
selects the whitespace in between and after notes/chords.

' \@<=<*\([a-g][',]*[1-8]* *\)\+>* address@hidden *'

Thanks,
Greg

- -- 
Twitter: @gregrs_uk
PGP key ID: 64907C8A
Fingerprint: EBD1 077F CCDD 841E A505 3FAA D2E8 592E 6490 7C8A
-----BEGIN PGP SIGNATURE-----

iQEcBAEBCAAGBQJZpycMAAoJEB7WhxSLszZlTOkH/RnVXE7agsIxEczBQrbbYY39
/W5KbnoVdAWbwEMgW7IvA/tbXJ/47HOckQohUM8/sfNW4Y95LMGUMFfSoU3ovCYH
fgKyCk8LU3s6x11T/qEwCgy1AXljC0C9jW+JGOc6wEOml2Nw7O6BQqaPh5KfkwjV
Pn8gsmtK2qLcgCqXDPDjHnng96UeWwMp4CUvRJhYE7gQMQ1p2AVnIu4rmmH0AXpw
2Li8XsjOeaXmbqpBrwUmLthahCV205V1u1FRFxvzQqVuRBBtF5MYO0XApQsopGlE
+XhIuOCEP4naZ0m+K+6fMC39UuaLAENlu0k6Lz4fVj6qVLA4plf1NQeVOlFqPN0=
=O3vO
-----END PGP SIGNATURE-----



reply via email to

[Prev in Thread] Current Thread [Next in Thread]