ds300 / patch-package

Fix broken node modules instantly 🏃🏽‍♀️💨
MIT License
10.39k stars 291 forks source link

Patch-package does't recognize changes in package.json file #142

Closed Gabrielcmp closed 5 years ago

Gabrielcmp commented 5 years ago

I don't know if this is a bug or a feature request and the package is supposed to work only on js files, but I need to patch the package.json file from the nedb package as reported in https://github.com/louischatriot/nedb/issues/531

But when I run the patch-package after changing it, it shows:

• Creating temporary folder • Installing nedb@1.8.0 with npm • Diffing your files with clean files ⁉️ Not creating patch file for package 'nedb' ⁉️ There don't appear to be any changes.

I tried to edit the index.js to test and it detected it normally. It would be great if the patcher could also detect changes in files other than .js

ds300 commented 5 years ago

Hi! 👋

You can patch package.json files but they are ignored by default. See the --include and --exclude options in the README.

aliberski commented 4 years ago

try this: npx patch-package package-name --exclude