From 0bb742ef33fe8f4ab8f4745b94355dab36ccb6cb Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sat, 5 Dec 2009 21:21:08 -0800 Subject: Use NULL instead of actual values in the vars table, so that var tweaks result in smaller diffs. --- modules/gallery/controllers/packager.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'modules') diff --git a/modules/gallery/controllers/packager.php b/modules/gallery/controllers/packager.php index 82c3c938..1354a01b 100644 --- a/modules/gallery/controllers/packager.php +++ b/modules/gallery/controllers/packager.php @@ -134,6 +134,11 @@ class Packager_Controller extends Controller { $line = preg_replace("/ENGINE=\S+ /", "", $line); } + // Null out ids in the vars table since it's an auto_increment table and this will result in + // more stable values so we'll have less churn in install.sql. + $line = preg_replace( + "/^INSERT INTO {vars} VALUES \(\d+/", "INSERT INTO {vars} VALUES (NULL", $line); + $buf .= $line; } $fd = fopen($sql_file, "wb"); -- cgit v1.2.3