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

fix: allow parentheses in catalog pathnames #1820

Merged
merged 2 commits into from
Dec 18, 2023
Merged

fix: allow parentheses in catalog pathnames #1820

merged 2 commits into from
Dec 18, 2023

Conversation

jozefmery
Copy link
Contributor

@jozefmery jozefmery commented Dec 17, 2023

Description

Escape parentheses in the pathname pattern according to the following issue: micromatch/micromatch#123
The solution uses the simplest possible approach: the String#replace method. I considered the escape-string-regexp package, but it seems that parentheses are the only problematic characters.

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update

Fixes #1819

Checklist

  • I have read the CONTRIBUTING and CODE_OF_CONDUCT docs (NOTE: I managed to run yarn test, but yarn release:test fails with the following message: The filename, directory name, or volume label syntax is incorrect. command not found: test:tsd. I believe this is unrelated to my changes and may warrant its own issue.)
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

Copy link

vercel bot commented Dec 17, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
js-lingui ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 17, 2023 4:42pm

@jozefmery jozefmery changed the title fix: allow parentheses in cathalog pathnames fix: allow parentheses in catalog pathnames Dec 17, 2023
Copy link

size-limit report 📦

Path Size
./packages/core/dist/index.mjs 2.81 KB (0%)
./packages/detect-locale/dist/index.mjs 723 B (0%)
./packages/react/dist/index.mjs 1.67 KB (0%)
./packages/remote-loader/dist/index.mjs 7.26 KB (0%)

Copy link

codecov bot commented Dec 17, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

❗ No coverage uploaded for pull request base (main@8830f2e). Click here to learn what that means.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1820   +/-   ##
=======================================
  Coverage        ?   76.39%           
=======================================
  Files           ?       81           
  Lines           ?     2072           
  Branches        ?      529           
=======================================
  Hits            ?     1583           
  Misses          ?      377           
  Partials        ?      112           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@andrii-bodnar andrii-bodnar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jozefmery thank you!

@andrii-bodnar andrii-bodnar merged commit f5fae0e into lingui:main Dec 18, 2023
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Vite] Parentheses in catalog pathnames causes them to be unrecognized
3 participants