Displaying 20 results from an estimated 600 matches similar to: "[PATCH] builder: small code simplification"
2014 Jan 16
0
[PATCH 3/3] builder: add a JSON output for --list
Simple JSON output for sources and templates, to be able to query them
with no need to parse unstructured outputs like the "--list-format long"
one.
---
builder/cmdline.ml | 3 +-
builder/list_entries.ml | 60 +++++++++++++++++++++++++++++++++++
builder/list_entries.mli | 2 +-
builder/test-virt-builder-list.sh | 67
2014 Jan 16
5
[PATCH 0/3] Add JSON output for virt-builder
Hi,
This small patch serie adds a JSON output for virt-builder.
This way it is possible to parse the list of available templates,
with no need to parse the unstructured and possibly changing short and
long outputs of virt-builder.
Pino Toscano (3):
builder: small refactor of the list output
builder: add --list-format
builder: add a JSON output for --list
builder/builder.ml
2014 Jan 22
2
[PATCH] builder: read all the available notes from the index
Switch the internal storage for the notes of each entry to a sorted list
with all the subkeys available (which should represent the translations
to various languages).
The current outputs are the same (i.e. still the untranslated notes), so
this is just internal refactoring/preparation.
---
builder/builder.ml | 4 ++--
builder/index_parser.ml | 19 +++++++++++++++----
2014 Oct 10
0
[PATCH 3/3] builder: use the JSON module
Switch to the JSON OCaml module for JSON output.
The resulting output is the same, except from an indentation level more
within lists.
---
builder/Makefile.am | 1 +
builder/list_entries.ml | 138 +++++++++++++++-----------------------
builder/test-virt-builder-list.sh | 134 ++++++++++++++++++------------------
3 files changed, 123 insertions(+), 150 deletions(-)
diff
2014 Feb 24
2
[PATCH] builder: add a mandatory 'arch' key in index files
Introduce a mandatory arch= key in all the entries of index files, to
identify which architecture is each. Adapt the long and JSON list
outputs to print also this new field.
This introduces an incompatibility with index files created with
virt-builder < 1.26, as they will be rejected until entries will have
the arch= key added (which is ignored by older virt-builder, so adding
it will not
2014 May 26
2
[PATCH] builder: support aliases for images (RHBZ#1098718).
---
builder/builder.ml | 12 ++++++++++++
builder/index_parser.ml | 16 ++++++++++++++++
builder/index_parser.mli | 4 ++++
builder/list_entries.ml | 17 +++++++++++++++++
builder/virt-builder.pod | 8 ++++++++
5 files changed, 57 insertions(+)
diff --git a/builder/builder.ml b/builder/builder.ml
index a0ef6d7..c317816 100644
--- a/builder/builder.ml
+++ b/builder/builder.ml
@@ -192,6
2014 Oct 10
4
[PATCH 1/3] Move JSON to mllib
Move the simple OCaml JSON writer to mllib, so that can be enhanced and
used also outside v2v.
---
mllib/JSON.ml | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++
mllib/JSON.mli | 26 ++++++++++++++++++++++++++
mllib/Makefile.am | 5 ++++-
po/POTFILES-ml | 2 +-
v2v/JSON.ml | 53 -----------------------------------------------------
v2v/JSON.mli | 26
2014 Jan 30
2
[PATCH] builder: output translated notes
Output all the translations available for the notes in the "verbose"
output and the JSON output, while trying to match the system langauge in
the "show notes" output.
The JSON output is slightly changed to handle translations, with the
"untranslated" notes being matched as "C". The version is not bumped
though, since there have been no stable releases with
2014 Oct 31
4
[PATCH] builder: move the gpgkey_type type from Sigchecker to Utils
No functional change, just code motion.
---
builder/builder.ml | 6 +++---
builder/list_entries.ml | 12 ++++++------
builder/list_entries.mli | 2 +-
builder/sigchecker.ml | 5 -----
builder/sigchecker.mli | 7 +------
builder/utils.ml | 5 +++++
6 files changed, 16 insertions(+), 21 deletions(-)
diff --git a/builder/builder.ml b/builder/builder.ml
index
2016 Jul 18
0
[PATCH 3/3] builder: improve the handling of list formats
Store them directly in List_entries, an adding helper function to
convert from string.
Also use Getopt.Symbol for them, so there is no need to manually reject
invalid formats.
---
builder/cmdline.ml | 21 +++++++++++----------
builder/cmdline.mli | 2 +-
builder/list_entries.ml | 19 ++++++++++++++++---
builder/list_entries.mli | 16 +++++++++++++++-
4 files changed, 43
2016 Jul 18
4
[PATCH 1/3] mllib: Getopt: point to man page as additional help
On error, point also to the man page of the current tool in addition to
'$TOOL --help'.
---
mllib/getopt-c.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/mllib/getopt-c.c b/mllib/getopt-c.c
index bf40f91..3efd5d3 100644
--- a/mllib/getopt-c.c
+++ b/mllib/getopt-c.c
@@ -69,8 +69,8 @@ cleanup_option_list (void *ptr)
static void __attribute__((noreturn))
2014 Oct 31
0
[PATCH] builder: pass Sources.source objects directly
Instead of passing the (uri, key, proxy) tuple around, pass the whole
Sources.source record; this requires creating proper Sources.source also
for uri+fingerprint passed via command line.
No functional changes.
---
builder/Makefile.am | 2 +-
builder/builder.ml | 17 +++++++++--------
builder/index_parser.ml | 14 +++++++-------
builder/index_parser.mli | 2 +-
2017 Oct 27
0
[PATCH v11 3/8] builder: change arch type to (string, string option) maybe.
In a future commit, the index parser will allow arch not to be set
for some cases. In such cases, it will be guessed by inspecting the
image, but we need to distinguish between a set value and a guessed
one. Using the '(string, string option) maybe' type will help it:
match arch with
| Either s -> (* This is a set value *)
| Or Some s -> (* This is a guessed value *)
2017 Nov 21
0
[PATCH v13 1/3] builder: change arch type to distinguish guesses
Change Index.arch to the type (Arch of string | GuessedArch of string).
In a future commit, the index parser will allow arch not to be set
for some cases. Thus arch value will be guessed by inspecting the
image. However we need to distinguish between a set value and a guessed
one. Using this new type will help it:
match arch with
| Arch s -> (* This is a set value *)
|
2017 Nov 13
0
[PATCH v12 1/3] builder: change arch type to distinguish guesses
Change Index.arch to the type (Arch of string | GuessedArch of string).
In a future commit, the index parser will allow arch not to be set
for some cases. Thus arch value will be guessed by inspecting the
image. However we need to distinguish between a set value and a guessed
one. Using this new type will help it:
match arch with
| Arch s -> (* This is a set value *)
|
2015 Jul 28
0
[PATCH 06/10] builder: split Index_parser.index in an own module
Move the index and entry definitions in an own Index module, together
with the (previously internal to Index_parser) print_entry debugging
function.
---
builder/Makefile.am | 2 +
builder/builder.ml | 36 +++++++--------
builder/index.ml | 117 +++++++++++++++++++++++++++++++++++++++++++++++
builder/index.mli | 41 +++++++++++++++++
builder/index_parser.ml | 96
2014 Feb 25
12
[PATCH 0/8] virt-builder: use .conf files for configuration
Hi,
attached there is a serie of patches that completes the work on making
virt-builder use .conf files, shipped in XDG directories, to configure
all the available sources of indexes used.
This also removes the hardcoded default location, replaced now with a
configuration file (which may be not used at all).
Thanks,
Pino Toscano (8):
builder: allow "no key" as key in Sigchecker
2013 Dec 04
4
[PATCH] builder: translate more user-visible strings
Translate also the "OS version" and "Notes" strings that appear in the
--long output.
---
builder/list_entries.ml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/builder/list_entries.ml b/builder/list_entries.ml
index 8c24fe2..a1d0696 100644
--- a/builder/list_entries.ml
+++ b/builder/list_entries.ml
@@ -47,7 +47,7 @@ let list_entries ?(list_long =
2015 Jul 28
19
[PATCH 00/10] RFC: builder: first support for Simple Streams metadata
Hi,
this series adds a basic support for Simple Streams v1.0 metadata
files. This makes it possible to create a repository .conf files with
[cirros]
uri=http://download.cirros-cloud.net
format=simplestreams
to read the latest version of each CirrOS image.
TODO items:
- a bit more testing: listing and creating images works, so the
current metadata is correct
- handle revisions, so newer
2017 Oct 04
0
[PATCH 2/9] ocaml: Replace pattern matching { field = field } with { field }.
If you have a struct containing ?field?, eg:
type t = { field : int }
then previously to pattern-match on this type, eg. in function
parameters, you had to write:
let f { field = field } =
(* ... use field ... *)
In OCaml >= 3.12 it is possible to abbreviate cases where the field
being matched and the variable being bound have the same name, so now
you can just write:
let f {