Hi!

> > Lost me.  What about sntp do you want to put on gitlab?
> 
> Oh, reading these in reverse order.  I think you are offering to
> add this as a Merge Request on GitLab?  Yes, that would be good.

Can I please send the patch via e-mail? I've been struggeling with
gitlab for an hour and whatever I do it keeps complaining that I'm not
allowed to push to the project (my own clone, in a branch).


regards
commit 097320eea017aacd531ae0a7dd5a22041fbd7025
Author: folkert van heusden <m...@vanheusden.com>
Date:   Tue Jan 3 08:55:14 2023 +0100

    ntpdig/sntp: added the "delay" to the json output.

diff --git a/ntpclients/ntpdig.py b/ntpclients/ntpdig.py
index ec597d09b..3c7135e91 100644
--- a/ntpclients/ntpdig.py
+++ b/ntpclients/ntpdig.py
@@ -216,12 +216,12 @@ def report(packet, json):
 
     if json:
         say('{"time":"%sT%s%s","offset":%f,"precision":%f,"host":"%s",'
-            '"ip":"%s","stratum":%s,"leap":"%s","adjusted":%s}\n'
+            '"ip":"%s","stratum":%s,"leap":"%s","adjusted":%s,"delay":%f}\n'
             % (date, tod, tz,
                packet.adjust(), packet.synchd(),
                packet.hostname, packet.resolved or packet.hostname,
                packet.stratum, packet.leap(),
-               "true" if adjusted else "false"))
+               "true" if adjusted else "false", packet.delta()))
     else:
         say("%s %s (%s) %+f +/- %f %s"
             % (date, tod, tz,
_______________________________________________
devel mailing list
devel@ntpsec.org
https://lists.ntpsec.org/mailman/listinfo/devel

Reply via email to