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

Fixes missing files when calling getManifest() with glob disabled #830

Merged
merged 1 commit into from
Mar 28, 2023

Conversation

sysrage
Copy link
Contributor

@sysrage sysrage commented Mar 27, 2023

When glob is set to false, the call to getManifest() was failing in Windows:

[ ERROR ] 2023-03-27T12:32:48.495Z ENOENT: no such file or directory, open 'C:\package.json'

This PR sets files to options.srcDir if options.glob is false. It works when globbing is disabled, but I don't know if it breaks anything when globbing is enabled.

@sysrage sysrage requested a review from ayushmanchhabra March 27, 2023 13:36
@ayushmanchhabra
Copy link
Collaborator

options.glob === true ? files : options.srcDir,

This doesn't work?

@sysrage
Copy link
Contributor Author

sysrage commented Mar 27, 2023

options.glob === true ? files : options.srcDir,

This doesn't work?

Nope. That line is long after your call to getManifest(). It's the getManifest() call that fails when files is an empty array.

Copy link
Collaborator

@ayushmanchhabra ayushmanchhabra left a comment

Choose a reason for hiding this comment

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

Hmm, I can see why this would happen. Thanks!

@ayushmanchhabra ayushmanchhabra merged commit 56cf9b2 into main Mar 28, 2023
@ayushmanchhabra ayushmanchhabra deleted the fix-glob-files branch March 28, 2023 05:17
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.

2 participants