diff --git a/contrib/libxo/configure.ac b/contrib/libxo/configure.ac index 03affa94921..852fed5818c 100644 --- a/contrib/libxo/configure.ac +++ b/contrib/libxo/configure.ac @@ -12,7 +12,7 @@ # AC_PREREQ(2.2) -AC_INIT([libxo], [1.0.2], [phil@juniper.net]) +AC_INIT([libxo], [1.0.4], [phil@juniper.net]) AM_INIT_AUTOMAKE([-Wall -Werror foreign -Wno-portability]) # Support silent build rules. Requires at least automake-1.11. diff --git a/contrib/libxo/doc/libxo-manual.html b/contrib/libxo/doc/libxo-manual.html index f65bdd18b4a..485faece05b 100644 --- a/contrib/libxo/doc/libxo-manual.html +++ b/contrib/libxo/doc/libxo-manual.html @@ -22011,7 +22011,7 @@ jQuery(function ($) { -April 2, 2019 +April 24, 2019

libxo: The Easy Way to Generate text, XML, JSON, and HTML output
libxo-manual

diff --git a/contrib/libxo/libxo/libxo.c b/contrib/libxo/libxo/libxo.c index 4ac351e1371..a70768814c1 100644 --- a/contrib/libxo/libxo/libxo.c +++ b/contrib/libxo/libxo/libxo.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014-2018, Juniper Networks, Inc. + * Copyright (c) 2014-2019, Juniper Networks, Inc. * All rights reserved. * This SOFTWARE is licensed under the LICENSE provided in the * ../Copyright file. By downloading, installing, copying, or otherwise diff --git a/contrib/libxo/libxo/xo_explicit.h b/contrib/libxo/libxo/xo_explicit.h index e2133e75f70..2611cf13ce7 100644 --- a/contrib/libxo/libxo/xo_explicit.h +++ b/contrib/libxo/libxo/xo_explicit.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2015, Juniper Networks, Inc. + * Copyright (c) 2019, Juniper Networks, Inc. * All rights reserved. * This SOFTWARE is licensed under the LICENSE provided in the * ../Copyright file. By downloading, installing, copying, or otherwise diff --git a/contrib/libxo/tests/core/saved/test_02.E.err b/contrib/libxo/tests/core/saved/test_02.E.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.E.err +++ b/contrib/libxo/tests/core/saved/test_02.E.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.E.out b/contrib/libxo/tests/core/saved/test_02.E.out index 6cc40e4d5da..499b5abc710 100644 --- a/contrib/libxo/tests/core/saved/test_02.E.out +++ b/contrib/libxo/tests/core/saved/test_02.E.out @@ -1,6 +1,10 @@ op create: [] [] [0] op open_container: [top] [] [0x40010] op open_container: [data] [] [0x40010] +op string: [name] [em0] [0x1080] +op string: [flags] [0x8843] [0x18] +op string: [name] [em0] [0x1088] +op string: [flags] [0x8843] [0x18] op string: [what] [braces] [0] op string: [length] [abcdef] [0] op content: [fd] [-1] [0] diff --git a/contrib/libxo/tests/core/saved/test_02.H.err b/contrib/libxo/tests/core/saved/test_02.H.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.H.err +++ b/contrib/libxo/tests/core/saved/test_02.H.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.H.out b/contrib/libxo/tests/core/saved/test_02.H.out index f1387a645a4..66a15850276 100644 --- a/contrib/libxo/tests/core/saved/test_02.H.out +++ b/contrib/libxo/tests/core/saved/test_02.H.out @@ -1,4 +1,4 @@ -
We are
{emit}
{ting}
some
braces
abcdef +
em0
em0
We are
{emit}
{ting}
some
braces
abcdef
abcdef: Bad file descriptor
improper use of profanity; ten yard penalty; first down
length
abcdef
close
-1
returned
Bad file descriptor
good
close
-1
returned
Bad fi
good
improper use of profanity; ten yard penalty; first down diff --git a/contrib/libxo/tests/core/saved/test_02.HIPx.err b/contrib/libxo/tests/core/saved/test_02.HIPx.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.HIPx.err +++ b/contrib/libxo/tests/core/saved/test_02.HIPx.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.HIPx.out b/contrib/libxo/tests/core/saved/test_02.HIPx.out index 7af26b39c1a..e2b51086d9b 100644 --- a/contrib/libxo/tests/core/saved/test_02.HIPx.out +++ b/contrib/libxo/tests/core/saved/test_02.HIPx.out @@ -1,9 +1,11 @@
+
em0
+
em0
We are
{emit}
{ting}
some
-
braces
+
braces
abcdef @@ -19,23 +21,23 @@
length
-
abcdef
+
abcdef
close
-
-1
+
-1
returned
-
Bad file descriptor
+
Bad file descriptor
-
good
+
good
close
-
-1
+
-1
returned
-
Bad fi
+
Bad fi
-
good
+
good
improper use of profanity; ten yard penalty; first down @@ -43,155 +45,155 @@
-
20
+
20
-
30
+
30
-
40
+
40
-
file
+
file
-
0
+
0
bytes
-
1
+
1
byte
-
2
+
2
bytes
-
3
+
3
bytes
-
4
+
4
bytes
-
10
+
10
/
-
20
+
20
/
-
30
+
30
mbufs <&> in use (current/cache/total)
-
50
+
50
from
-
Boston
+
Boston
-
64
+
64
left out of
-
640
+
640
-
64
+
64
left out of
-
640
+
640
beforeworkingafter:
-
string
+
string
:
-
10
-
11
+
10
+
11
-
1010
+
1010
packets here/there/everywhere
-
1010
+
1010
packets here/there/everywhere
(
-
15
+
15
/
-
20
+
20
/
-
125
+
125
)
(
-
15
+
15
/
-
20
+
20
/
-
125
+
125
)
(
-
15
+
15
/
-
20
+
20
/
-
125
+
125
)
(
-
15
+
15
/
-
20
+
20
/
-
125
+
125
)
Humanize:
-
21
+
21
,
-
57 K
+
57 K
,
-
96M
+
96M
,
-
44M
+
44M
,
-
1.2G
+
1.2G
-
one
+
one
-
two
+
two
-
three
+
three
-
(null)
+
(null)
1:
-
1000
+
1000
2:
-
test5000
+
test5000
3:
-
ten-longx
+
ten-longx
4:
-
xtest
+
xtest
this is an error
@@ -208,10 +210,10 @@
V1/V2 packets
:
-
10
+
10
-
0004
+
0004
tries
diff --git a/contrib/libxo/tests/core/saved/test_02.HP.err b/contrib/libxo/tests/core/saved/test_02.HP.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.HP.err +++ b/contrib/libxo/tests/core/saved/test_02.HP.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.HP.out b/contrib/libxo/tests/core/saved/test_02.HP.out index f7c9d9b44fe..2a4b954c94e 100644 --- a/contrib/libxo/tests/core/saved/test_02.HP.out +++ b/contrib/libxo/tests/core/saved/test_02.HP.out @@ -1,4 +1,6 @@
+
em0
+
em0
We are
{emit}
{ting}
diff --git a/contrib/libxo/tests/core/saved/test_02.J.err b/contrib/libxo/tests/core/saved/test_02.J.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.J.err +++ b/contrib/libxo/tests/core/saved/test_02.J.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.J.out b/contrib/libxo/tests/core/saved/test_02.J.out index 65732c5c28d..d6d175339c7 100644 --- a/contrib/libxo/tests/core/saved/test_02.J.out +++ b/contrib/libxo/tests/core/saved/test_02.J.out @@ -1 +1 @@ -{"top": {"data": {"what":"braces","length":"abcdef","fd":-1,"error":"Bad file descriptor","test":"good","fd":-1,"error":"Bad fi","test":"good","lines":20,"words":30,"characters":40, "bytes": [0,1,2,3,4],"mbuf-current":10,"mbuf-cache":20,"mbuf-total":30,"distance":50,"location":"Boston","memory":64,"total":640,"memory":64,"total":640,"ten":10,"eleven":11,"unknown":1010,"unknown":1010,"min":15,"cur":20,"max":125,"min":15,"cur":20,"max":125,"min":15,"cur":20,"max":125,"min":15,"cur":20,"max":125,"val1":21,"val2":58368,"val3":100663296,"val4":44470272,"val5":1342172800, "flag": ["one","two","three"],"works":null,"empty-tag":true,"t1":"1000","t2":"test5000","t3":"ten-longx","t4":"xtest", "__error": {"message":"this is an error"}, "__error": {"message":"two more errors"}, "__warning": {"message":"this is an warning"}, "__warning": {"message":"two more warnings"},"count":10,"test":4, "error": {"message":"Shut 'er down, Clancey! She's a-pumpin' mud! <>!,\"!<>\n"}}}} +{"top": {"data": {"name":"em0","flags":"0x8843","name":"em0","flags":"0x8843","what":"braces","length":"abcdef","fd":-1,"error":"Bad file descriptor","test":"good","fd":-1,"error":"Bad fi","test":"good","lines":20,"words":30,"characters":40, "bytes": [0,1,2,3,4],"mbuf-current":10,"mbuf-cache":20,"mbuf-total":30,"distance":50,"location":"Boston","memory":64,"total":640,"memory":64,"total":640,"ten":10,"eleven":11,"unknown":1010,"unknown":1010,"min":15,"cur":20,"max":125,"min":15,"cur":20,"max":125,"min":15,"cur":20,"max":125,"min":15,"cur":20,"max":125,"val1":21,"val2":58368,"val3":100663296,"val4":44470272,"val5":1342172800, "flag": ["one","two","three"],"works":null,"empty-tag":true,"t1":"1000","t2":"test5000","t3":"ten-longx","t4":"xtest", "__error": {"message":"this is an error"}, "__error": {"message":"two more errors"}, "__warning": {"message":"this is an warning"}, "__warning": {"message":"two more warnings"},"count":10,"test":4, "error": {"message":"Shut 'er down, Clancey! She's a-pumpin' mud! <>!,\"!<>\n"}}}} diff --git a/contrib/libxo/tests/core/saved/test_02.JP.err b/contrib/libxo/tests/core/saved/test_02.JP.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.JP.err +++ b/contrib/libxo/tests/core/saved/test_02.JP.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.JP.out b/contrib/libxo/tests/core/saved/test_02.JP.out index 9e40703c613..cf211401be6 100644 --- a/contrib/libxo/tests/core/saved/test_02.JP.out +++ b/contrib/libxo/tests/core/saved/test_02.JP.out @@ -1,6 +1,10 @@ { "top": { "data": { + "name": "em0", + "flags": "0x8843", + "name": "em0", + "flags": "0x8843", "what": "braces", "length": "abcdef", "fd": -1, diff --git a/contrib/libxo/tests/core/saved/test_02.T.err b/contrib/libxo/tests/core/saved/test_02.T.err index 80fabe31c77..bae8367624f 100644 --- a/contrib/libxo/tests/core/saved/test_02.T.err +++ b/contrib/libxo/tests/core/saved/test_02.T.err @@ -1 +1,2 @@ +test_02.test: key field emitted after normal value field: 'name' Shut 'er down, Clancey! She's a-pumpin' mud! <>!,"!<> diff --git a/contrib/libxo/tests/core/saved/test_02.T.out b/contrib/libxo/tests/core/saved/test_02.T.out index d65e7c50e9b..5b22c1615bb 100644 --- a/contrib/libxo/tests/core/saved/test_02.T.out +++ b/contrib/libxo/tests/core/saved/test_02.T.out @@ -1,4 +1,4 @@ -We are {emit}{ting} some braces +em0 em0 We are {emit}{ting} some braces abcdef abcdef: Bad file descriptor improper use of profanity; ten yard penalty; first down diff --git a/contrib/libxo/tests/core/saved/test_02.X.err b/contrib/libxo/tests/core/saved/test_02.X.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.X.err +++ b/contrib/libxo/tests/core/saved/test_02.X.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.X.out b/contrib/libxo/tests/core/saved/test_02.X.out index 49e9355514e..2eb122d00c8 100644 --- a/contrib/libxo/tests/core/saved/test_02.X.out +++ b/contrib/libxo/tests/core/saved/test_02.X.out @@ -1,4 +1,4 @@ -bracesabcdef +em00x8843em00x8843bracesabcdef abcdef: Bad file descriptor improper use of profanity; ten yard penalty; first down abcdef-1Bad file descriptorgood-1Bad figoodimproper use of profanity; ten yard penalty; first down diff --git a/contrib/libxo/tests/core/saved/test_02.XP.err b/contrib/libxo/tests/core/saved/test_02.XP.err index e69de29bb2d..4bd358b8813 100644 --- a/contrib/libxo/tests/core/saved/test_02.XP.err +++ b/contrib/libxo/tests/core/saved/test_02.XP.err @@ -0,0 +1 @@ +test_02.test: key field emitted after normal value field: 'name' diff --git a/contrib/libxo/tests/core/saved/test_02.XP.out b/contrib/libxo/tests/core/saved/test_02.XP.out index e5172d35fd8..9c18c5edca4 100644 --- a/contrib/libxo/tests/core/saved/test_02.XP.out +++ b/contrib/libxo/tests/core/saved/test_02.XP.out @@ -1,5 +1,9 @@ + em0 + 0x8843 + em0 + 0x8843 braces abcdef diff --git a/contrib/libxo/tests/core/test_01.c b/contrib/libxo/tests/core/test_01.c index dfadc754cab..2957472464b 100644 --- a/contrib/libxo/tests/core/test_01.c +++ b/contrib/libxo/tests/core/test_01.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Juniper Networks, Inc. + * Copyright (c) 2014-2019, Juniper Networks, Inc. * All rights reserved. * This SOFTWARE is licensed under the LICENSE provided in the * ../Copyright file. By downloading, installing, copying, or otherwise diff --git a/contrib/libxo/tests/core/test_02.c b/contrib/libxo/tests/core/test_02.c index cf98d34f1f4..b3d5ca92e20 100644 --- a/contrib/libxo/tests/core/test_02.c +++ b/contrib/libxo/tests/core/test_02.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014, Juniper Networks, Inc. + * Copyright (c) 2014-2019, Juniper Networks, Inc. * All rights reserved. * This SOFTWARE is licensed under the LICENSE provided in the * ../Copyright file. By downloading, installing, copying, or otherwise @@ -48,6 +48,12 @@ main (int argc, char **argv) xo_open_container("data"); + xo_emit("{kt:name/%-*.*s}{eq:flags/0x%x}", + 5, 5, "em0", 34883); + + xo_emit("{d:/%-*.*s}{etk:name}{eq:flags/0x%x}", + 5, 5, "em0", "em0", 34883); + xo_emit("We are {{emit}}{{ting}} some {:what}\n", "braces"); xo_message("abcdef"); diff --git a/contrib/libxo/xo/xo.c b/contrib/libxo/xo/xo.c index f74a1b25f56..d17c738cb54 100644 --- a/contrib/libxo/xo/xo.c +++ b/contrib/libxo/xo/xo.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2014-2018, Juniper Networks, Inc. + * Copyright (c) 2014-2019, Juniper Networks, Inc. * All rights reserved. * This SOFTWARE is licensed under the LICENSE provided in the * ../Copyright file. By downloading, installing, copying, or otherwise diff --git a/lib/libxo/add.man b/lib/libxo/add.man index 83726d75ce9..42e0217c5f0 100644 --- a/lib/libxo/add.man +++ b/lib/libxo/add.man @@ -3,10 +3,10 @@ .Fx uses .Nm libxo -version 0.9.0. +version 1.0.4. Complete documentation can be found on github: .Bd -literal -offset indent -http://juniper.github.io/libxo/0.9.0/libxo\-manual.html +http://juniper.github.io/libxo/1.0.4/libxo\-manual.html .Ed .Pp .Nm libxo diff --git a/lib/libxo/xo_config.h b/lib/libxo/xo_config.h index c73c5b9b1e0..33b29a0f906 100644 --- a/lib/libxo/xo_config.h +++ b/lib/libxo/xo_config.h @@ -183,16 +183,16 @@ /* #undef LIBXO_TEXT_ONLY */ /* Version number as dotted value */ -#define LIBXO_VERSION "1.0.2" +#define LIBXO_VERSION "1.0.4" /* Version number extra information */ #define LIBXO_VERSION_EXTRA "" /* Version number as a number */ -#define LIBXO_VERSION_NUMBER 1000002 +#define LIBXO_VERSION_NUMBER 1000004 /* Version number as string */ -#define LIBXO_VERSION_STRING "1000002" +#define LIBXO_VERSION_STRING "1000004" /* Enable local wcwidth implementation */ #define LIBXO_WCWIDTH 1 @@ -210,7 +210,7 @@ #define PACKAGE_NAME "libxo" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "libxo 1.0.2" +#define PACKAGE_STRING "libxo 1.0.4" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "libxo" @@ -219,7 +219,7 @@ #define PACKAGE_URL "" /* Define to the version of this package. */ -#define PACKAGE_VERSION "1.0.2" +#define PACKAGE_VERSION "1.0.4" /* If using the C implementation of alloca, define if you know the direction of stack growth for your system; otherwise it will be @@ -236,7 +236,7 @@ /* #undef USE_INT_RETURN_CODES */ /* Version number of package */ -#define VERSION "1.0.2" +#define VERSION "1.0.4" /* Retain hash bucket size */ /* #undef XO_RETAIN_SIZE */ diff --git a/usr.bin/xohtml/xohtml.sh b/usr.bin/xohtml/xohtml.sh index 93e6ef78065..b72452a7a45 100755 --- a/usr.bin/xohtml/xohtml.sh +++ b/usr.bin/xohtml/xohtml.sh @@ -12,7 +12,7 @@ # BASE=/usr/share/libxo -VERSION=1.0.2 +VERSION=1.0.4 CMD=cat DONE= WEB=http://juniper.github.io/libxo/${VERSION}/xohtml