Sorry for the monolithic issue and patch, but it was easier this way. Lots of these fixes are based on changes I made working on the packaging script for http://topnotchthemes.com and I'm just now getting a chance to fold them in upstream.
A) Since we're already calling node_save() on each release node, that invokes hook_nodeapi(), which eventually triggers project_release_check_supported_versions(). So, we're needlessly calling all that crap twice, and it also majorly complicates the query, since we no longer care about the API tid. If we did want that tid, we should just get it from {prn}.version_api_tid now that it's denormalized. But, in fact, we don't care about it at all. simpler_query++ yay.
B) Renamed the variables holding various file paths to use a _tgz suffix to pave the way for #11416: Please provide *.zip downloads.
C) Fixed the mindless wd_msg("%id has changed, re-packaged.", array('%id' => $id), $view_link); message to be conditional based on if we actually re-packaged something or just packaged it for the first time.
D) We now use getmypid() when initializing the $tmp_dir for a given packaging run, to avoid collisions in case the script is running simultaneously (see also #313726: Add locking to package-release-nodes.php).
I'd also like to split out all the new drush_make code for profiles into a separate function, but I'll do that in a separate issue + patch, since it's unrelated to these changes.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 649546-2.package-release-nodes-cleanup.patch | 10.44 KB | dww |
| #1 | 649546-1.package-release-nodes-cleanup.patch | 10.4 KB | dww |
Comments
Comment #1
dwwComment #2
dww- fixed a few problems from variables that were recently renamed by hunmonk
- also, since we already initialize $tgz_exists, we can just reuse that when testing file age stuff for branches
Comment #3
dwwCommitted to HEAD
Comment #4
dwwDeployed via d.o SVN.