Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

conventional-commits-parser: the commit parser shouldn't consider URLs with an anchor as a reference #1016

Open
2 of 4 tasks
tehraninasab opened this issue Jun 19, 2023 · 0 comments

Comments

@tehraninasab
Copy link

tehraninasab commented Jun 19, 2023

Steps to Reproduce (for bugs)

Run the parser against a commit message like

foo: this is a title

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus
pellentesque feugiat volutpat [1]. Suspendisse potenti. Sed eu 
suscipit diam [2]. Nullam tincidunt erat dapibus mi dignissim, vel
lacinia mauris suscipit. Integer in [3].

[1] https://firstUrl.com
[2] https://secondUrl.com#anchor
[3] https://thirdUrl.com

Current Behavior

The body field of the parsed object becomes:

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus
pellentesque feugiat volutpat [1]. Suspendisse potenti. Sed eu 
suscipit diam [2]. Nullam tincidunt erat dapibus mi dignissim, vel
lacinia mauris suscipit. Integer in [3].

[1] https://firstUrl.com

And the following line ends up in the references field of the parsed object:

[2] https://secondUrl.com#anchor

Expected Behavior

A URL with an anchor shouldn't be considered a reference.

Affected packages

  • cli
  • core
  • prompt
  • config-angular

Your Environment

Executable Version
git --version 2.34.1
node --version v18.16.0
Mersho added a commit to Mersho/conventional-changelog that referenced this issue Feb 5, 2024
Mersho added a commit to Mersho/conventional-changelog that referenced this issue Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant