commit 4a1fa0b13ce1db6fb5bb0b717bbc4993cdbe351d Author: Arkadiusz MiĆkiewicz <ar...@maven.pl> Date: Mon Nov 12 18:03:17 2018 +0100
Handle multiline replies. pldnotify.awk | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) --- diff --git a/pldnotify.awk b/pldnotify.awk index 728b0f4..ff4a602 100755 --- a/pldnotify.awk +++ b/pldnotify.awk @@ -747,10 +747,13 @@ function rmo_check(name, sourceurl, cmd, ver) { sourceurl = "https://release-monitoring.org/api/project/pld-linux/" name cmd = "curl -m 45 -sf " sourceurl d("rmo: " cmd); - cmd | getline data + dataall = "" + while (cmd | getline data) { + dataall = dataall "\n" data + } close(cmd) - if (data) { - cmd = "echo 'var data='\"" data "\"';if (data.version) process.stdout.write(data.version)' | node" + if (dataall) { + cmd = "echo 'var data='\"" dataall "\"';if (data.version) process.stdout.write(data.version)' | node" d("rmo: " cmd); cmd | getline ver close(cmd) ================================================================ ---- gitweb: http://git.pld-linux.org/gitweb.cgi/packages/pldnotify.git/commitdiff/4a1fa0b13ce1db6fb5bb0b717bbc4993cdbe351d _______________________________________________ pld-cvs-commit mailing list pld-cvs-commit@lists.pld-linux.org http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit