arvinxx / gitmoji-commit-workflow

😉 Gitmoji Commit Workflow

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Squash commits broken due to `#`

e1en0r opened this issue · comments

As the title says, squash commits have the format :sparkles: feat: commit message (#291) and this breaks the regex matching. To be more precise, I actually think it's the closing parenthesis that does it?

As a result squash commits are excluded from the changelog and from the semantic versioning.

I think this might work Regex101

^(?::\w*:|(?:\ud83c[\udf00-\udfff])|(?:\ud83d[\udc00-\ude4f\ude80-\udeff])|[\u2600-\u2B55])\s(?<type>\w*)(?:\((?<scope>.*)\))?!?:\s(?<subject>(?:(?!#).)*(?:(?!\s).))(?:\s\(?(?<ticket>#\d*)\)?)?$