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: npm 8 does not install plugin dependencies #229

Merged

Conversation

erisu
Copy link
Member

@erisu erisu commented May 19, 2022

Motivation and Context

Installing Cordova Electron plugins does not install the Electron scope dependencies since npm 8.

Might be related to: npm/cli#2339

Description

This PR will npm install the sub-package dependencies before installing the sub-package to the Electron app scope.

The only potential side-efect is a slight increase in performance, but this resolves the changes that were made in npm 7 or 8.

npm 8 will only create a symlink to the sub-package without installing.

Testing

  • npm t
  • cordova run with cordova-plugin-device installed.

Checklist

  • I've run the tests to see all new and existing tests pass
  • I added automated test coverage as appropriate for this change
  • Commit is prefixed with (platform) if this change only applies to one platform (e.g. (android))
  • If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct keyword to close issues using keywords)
  • I've updated the documentation if necessary

@erisu erisu added the bug label May 19, 2022
@erisu erisu added this to the 3.1.0 milestone May 19, 2022
@codecov-commenter
Copy link

codecov-commenter commented May 19, 2022

Codecov Report

Merging #229 (fa51d19) into master (de5e8bd) will not change coverage.
The diff coverage is 100.00%.

@@            Coverage Diff            @@
##            master      #229   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           14        14           
  Lines          653       654    +1     
=========================================
+ Hits           653       654    +1     
Impacted Files Coverage Δ
lib/handler.js 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update de5e8bd...fa51d19. Read the comment docs.

@erisu erisu merged commit 87960a1 into apache:master May 20, 2022
@erisu erisu deleted the fix/npm-install-electron-app-linked-package-dep branch May 20, 2022 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants