-
Notifications
You must be signed in to change notification settings - Fork 243
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
Prevent updating package.json if there are no actual changes #694
Comments
On a related note, when I run Again, the contents of config.xml didn't really change, just the order of tags. Whereas, package.json had zero changes (even to the order of properties), yet was written to, thus updating its modified date. |
This also includes fixes for writing package.json with the correct newlines, which should address the complaints raised in [1] and possibly [2]. 1. apache/cordova-cli#353 2. apache#694
This also includes fixes for writing package.json with the correct newlines, which should address the complaints raised in [1] and possibly [2]. 1. apache/cordova-cli#353 2. apache#694
* GH-832: Look at devDeps for restoring platforms This also includes fixes for writing package.json with the correct newlines, which should address the complaints raised in [1] and possibly [2]. 1. apache/cordova-cli#353 2. #694 * Ensure a failure to restore stops the build This has been a recurring frustration over several years, and nobody can seem to explain why we would want to silently ignore restore failures for platforms and plugins rather than surfacing them and failing the remainder of the build steps.
I use several additional tools with Cordova for build management. Some of those watch for changes in files in order to rebuild/redistribute. Many hard-code watching the package.json file for changes. When running
cordova serve
, that callscordova prepare
, and package.json gets updated (so does config.xml), whether there are actually changes to it or not (e.g., no results from a diff). This causes those build watchers to fire, rebuild, copy some files to www, which causes Cordova's auto-reload to kick in, which updates package.json again, which continues this infinite cycle.Is there a way to avoid writing the exact same content to package.json that already exists in that file on every restart/reload? I get we need config.xml and package.json to "jive" but if there's no diff between what Cordova is about to write to package.json and what's already in package.json, can we skip the write?
Here is a Gist with my 2 files.
The text was updated successfully, but these errors were encountered: