Skip to content

chord regex #3

@eyaler

Description

@eyaler

hi!

in:
pattern = "(\[ch\])([A-G]+)(\/[A-G]*[b#])*([(?m)|(?m\d)|(?b\d)|(?#\d)|(?maj\d)|(?add\d)|(?sus\d)|(?aug)|(?aug\d)|(?dim)|(?dim\d)]*)(\/[A-G]*[b#])*(\[\/ch\])"

i think the chord type part of the regex is wrong for several reasons:

  1. everything is in a charset [] so it is taken by the character treating the (, ), ?, |, etc as characters
  2. the (?...) syntax is wrong

it would still mostly work but can get in some noise

thanks for your awesome project. i am using your scraper here: https://github.com/eyaler/uku3le (now being reworked)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions