summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2018-04-22 17:10:33 +0200
committerErich Eckner <git@eckner.net>2018-04-22 17:10:33 +0200
commit4e708195f1ccb3c2abad5cc6335b4b5d7dd17ffa (patch)
tree0de71df5b352fd40d0a4527d0a39bd2ca8dd8305 /bin
parent3e74fde47ed058a59040e68c0ce2b3153563da92 (diff)
downloadbuilder-4e708195f1ccb3c2abad5cc6335b4b5d7dd17ffa.tar.xz
bin/db-update,bin/return-assignment: update `binary_packages`.`last_moved`
Diffstat (limited to 'bin')
-rwxr-xr-xbin/db-update4
-rwxr-xr-xbin/return-assignment3
2 files changed, 5 insertions, 2 deletions
diff --git a/bin/db-update b/bin/db-update
index 54d2f87..98bc884 100755
--- a/bin/db-update
+++ b/bin/db-update
@@ -392,7 +392,9 @@ for source_stability in 'testing' 'staging'; do
printf ' JOIN `replaced_binary_packages` ON `binary_packages`.`id`=`replaced_binary_packages`.`id`;\n'
printf 'UPDATE `binary_packages`'
printf ' JOIN `moved_binary_packages` ON `binary_packages`.`id`=`moved_binary_packages`.`id`'
- printf ' SET `binary_packages`.`repository`=`moved_binary_packages`.`new_repository`;\n'
+ printf ' SET `binary_packages`.`repository`=`moved_binary_packages`.`new_repository`,'
+ printf ' `binary_packages`.`last_moved`=NOW()'
+ printf ' WHERE `binary_packages`.`repository`!=`moved_binary_packages`.`new_repository`;\n'
} | \
mysql_run_query
done
diff --git a/bin/return-assignment b/bin/return-assignment
index 9e64ff0..1b7a872 100755
--- a/bin/return-assignment
+++ b/bin/return-assignment
@@ -536,7 +536,8 @@ trigger_mirror_refreshs
base64 -w0
)"
printf ' `binary_packages`.`has_issues`=0,'
- printf ' `binary_packages`.`is_tested`=0'
+ printf ' `binary_packages`.`is_tested`=0,'
+ printf ' `binary_packages`.`last_moved`=NOW()'
printf ' WHERE `build_slaves`.`name`=from_base64("%s")' \
"$(
printf '%s' "${slave}" | \