-
Notifications
You must be signed in to change notification settings - Fork 986
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
refactor: cleanup create script #1193
Conversation
- remove update_cordova_subproject export - remove updateSubprojectHelp export
fs-extra's copySync creates any missing destination directories
fs-extra's removeSync removes anything and nothing w/out throwing
I would actually argue that this change is not actually breaking, since I would not consider the removed module exports public API. |
Codecov Report
@@ Coverage Diff @@
## master #1193 +/- ##
=======================================
Coverage 75.15% 75.15%
=======================================
Files 13 13
Lines 1658 1658
=======================================
Hits 1246 1246
Misses 412 412 Continue to review full report at Codecov.
|
* refactor!(create): make helper functions module-private - remove update_cordova_subproject export - remove updateSubprojectHelp export * refactor(create): cleanup, condense & rename update_cordova_subproject * refactor(create): cleanup copyJsAndCordovaLib * refactor(create): drop unused param of copyJsAndCordovaLib * refactor(create): use loop to copy files in copyJsAndCordovaLib * refactor(create): delete obsolete ensureDirSync in copyJsAndCordovaLib fs-extra's copySync creates any missing destination directories * refactor(create): simplify deletion logic in copyJsAndCordovaLib fs-extra's removeSync removes anything and nothing w/out throwing Co-authored-by: Erisu <erisu@apache.org>
Motivation and Context
This takes the changes from the first four commits of #1191 and adds a few further simplifications in the affected code areas.
I pulled this out to reduce the scope of said PR and since I already reviewed this part of the changes.
Description
From #1191:
updateSubprojectHelp
update_cordova_subproject
update_cordova_subproject
toupdateCordovaSubproject
updateCordovaSubproject
to take in two static arguments:projectXcodePath
which is the path to project's xcodeprojcordovaLibXcodePath
which is the path to the CordovaLib's xcodeproj. (Note: it maybe a symbolic link when--link
flag is added when installing platform)AbsParentPath
AbsProjectPath
relpath
updateSubprojectHelp
New:
copyJsAndCordovaLib
Testing
npm t