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(core): handle single quotes inside file paths #9160

Merged
merged 2 commits into from Jul 21, 2023
Merged

Conversation

Josh-Cena
Copy link
Collaborator

@Josh-Cena Josh-Cena commented Jul 20, 2023

Pre-flight checklist

Motivation

Test Plan

Test links

Deploy preview: https://deploy-preview-_____--docusaurus-2.netlify.app/

Related issues/PRs

@Josh-Cena Josh-Cena added the pr: bug fix This PR fixes a bug in a past release. label Jul 20, 2023
@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jul 20, 2023
@Sainan
Copy link
Contributor

Sainan commented Jul 20, 2023

Just FYI, " is an acceptable file name character on Linux. Nevermind, I guess escapePath does take care of that, just apostrophe was an edge case due to the javascript style.

@netlify
Copy link

netlify bot commented Jul 20, 2023

[V2]

Name Link
🔨 Latest commit 0cac45b
🔍 Latest deploy log https://app.netlify.com/sites/docusaurus-2/deploys/64b9535d1857690008c24bd8
😎 Deploy Preview https://deploy-preview-9160--docusaurus-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@github-actions
Copy link

github-actions bot commented Jul 20, 2023

⚡️ Lighthouse report for the deploy preview of this PR

URL Performance Accessibility Best Practices SEO PWA Report
/ 🔴 43 🟢 97 🟢 92 🟢 100 🟠 89 Report
/docs/installation 🟠 76 🟢 100 🟢 92 🟢 100 🟠 89 Report

@Josh-Cena
Copy link
Collaborator Author

Yes, which is why I added a note to the escapePath function—it already handles double quotes and in other places where we use it, we already use double quotes.

@github-actions
Copy link

github-actions bot commented Jul 20, 2023

Size Change: +473 B (0%)

Total Size: 1.1 MB

Filename Size Change
website/.docusaurus/globalData.json 117 kB +122 B (0%)
website/build/assets/js/main.********.js 828 kB +351 B (0%)
ℹ️ View Unchanged
Filename Size
website/build/assets/css/styles.********.css 113 kB
website/build/index.html 41 kB

compressed-size-action

Copy link
Collaborator

@slorber slorber left a comment

Choose a reason for hiding this comment

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

Looks good to me, but how can we check this works in practice? Maybe add a dogfood doc and we'll see if our site builds?

@slorber slorber merged commit cd61c7b into main Jul 21, 2023
29 of 30 checks passed
@slorber slorber deleted the escape-module-path branch July 21, 2023 13:16
slorber pushed a commit to VinceCYLiao/docusaurus that referenced this pull request Aug 3, 2023
This was referenced Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed Signed Facebook CLA pr: bug fix This PR fixes a bug in a past release.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Apostrophe in file name breaks registry.js
4 participants