Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2018-01-22 08:54:47 +0100
committerErich Eckner <git@eckner.net>2018-01-22 08:54:47 +0100
commitf8ffc4a1e58df67045f9e88e6b8c99490f0e1134 (patch)
tree38ca41c20cbefcefc428c87b83dbfcd2a5b7fe20
parent44e86866de30f7c9caaf0af1e4c632af61d95812 (diff)
bin/build-master-status-from-mysql: style
-rwxr-xr-xbin/build-master-status-from-mysql19
1 files changed, 10 insertions, 9 deletions
diff --git a/bin/build-master-status-from-mysql b/bin/build-master-status-from-mysql
index 6dacc5e..85185b7 100755
--- a/bin/build-master-status-from-mysql
+++ b/bin/build-master-status-from-mysql
@@ -8,15 +8,16 @@
. "${base_dir}/bin/mysql-functions"
# shellcheck disable=SC2016
-${mysql_command} -e '
- SELECT `build_slaves`.`name`,`build_slaves`.`operator`,`package_sources`.`pkgbase`,`build_slaves`.`last_connection`
- FROM `build_slaves`
- LEFT JOIN `build_assignments` ON
- `build_slaves`.`currently_building`=`build_assignments`.`id`
- LEFT JOIN `package_sources` ON
- `build_assignments`.`package_source`=`package_sources`.`id`
- ORDER BY `build_slaves`.`last_connection`
-' --html | \
+{
+ printf 'SELECT `build_slaves`.`name`,`build_slaves`.`operator`,`package_sources`.`pkgbase`,`build_slaves`.`last_connection`'
+ printf ' FROM `build_slaves`'
+ printf ' LEFT JOIN `build_assignments` ON'
+ printf ' `build_slaves`.`currently_building`=`build_assignments`.`id`'
+ printf ' LEFT JOIN `package_sources` ON'
+ printf ' `build_assignments`.`package_source`=`package_sources`.`id`'
+ printf ' ORDER BY `build_slaves`.`last_connection`'
+} | \
+ ${mysql_command} --html | \
sed '
s,</TR>,\0\n,g
' | \