search for: printable_nam

Displaying 20 results from an estimated 79 matches for "printable_nam".

Did you mean: printable_name
2014 Feb 24
2
[PATCH] builder: add a mandatory 'arch' key in index files
...| 7 +++++++ builder/test-virt-builder-list.sh | 14 ++++++++++++++ 5 files changed, 35 insertions(+) diff --git a/builder/index_parser.ml b/builder/index_parser.ml index 2d4a642..de4d72e 100644 --- a/builder/index_parser.ml +++ b/builder/index_parser.ml @@ -27,6 +27,7 @@ and entry = { printable_name : string option; (* the name= field *) osinfo : string option; file_uri : string; + arch : string; signature_uri : string option; (* deprecated, will be removed in 1.26 *) checksum_sha512 : string option; revision : int; @@ -43,6 +44,7 @@ and entry = { let print_ent...
2015 Jul 28
0
[PATCH 06/10] builder: split Index_parser.index in an own module
...te to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + *) + +open Common_gettext.Gettext +open Common_utils + +open Utils + +open Printf +open Unix + +type index = (string * entry) list (* string = "os-version" *) +and entry = { + printable_name : string option; (* the name= field *) + osinfo : string option; + file_uri : string; + arch : string; + signature_uri : string option; (* deprecated, will be removed in 1.26 *) + checksums : Checksums.csum_t list option; + revision : int; + format : string option; + size : in...
2014 May 26
2
[PATCH] builder: support aliases for images (RHBZ#1098718).
..._parser.ml @@ -38,11 +38,14 @@ and entry = { lvexpand : string option; notes : (string * string) list; hidden : bool; + aliases : string list option; sigchecker : Sigchecker.t; proxy : Downloader.proxy_mode; } +let list_separator = " " + let print_entry chan (name, { printable_name = printable_name; file_uri = file_uri; arch = arch; @@ -56,6 +59,7 @@ let print_entry chan (name, { printable_name = printable_name; expand = expand; lvexpand = lvexpand;...
2017 Nov 21
0
[PATCH v13 1/3] builder: change arch type to distinguish guesses
...d a temporary file flag. The temporary file flag is [true] iff the downloaded file is temporary and should be deleted by the diff --git a/builder/index.ml b/builder/index.ml index 84f66c265..65d97ea7e 100644 --- a/builder/index.ml +++ b/builder/index.ml @@ -30,7 +30,7 @@ and entry = { printable_name : string option; (* the name= field *) osinfo : string option; file_uri : string; - arch : string; + arch : arch; signature_uri : string option; (* deprecated, will be removed in 1.26 *) checksums : Checksums.csum_t list option; revision : Utils.revision; @@ -46,6 +46...
2017 Nov 13
0
[PATCH v12 1/3] builder: change arch type to distinguish guesses
...deleted by the diff --git a/builder/index.ml b/builder/index.ml index 84f66c265..5bc11b6f7 100644 --- a/builder/index.ml +++ b/builder/index.ml @@ -25,12 +25,13 @@ open Utils open Printf open Unix + type index = (string * entry) list (* string = "os-version" *) and entry = { printable_name : string option; (* the name= field *) osinfo : string option; file_uri : string; - arch : string; + arch : arch; signature_uri : string option; (* deprecated, will be removed in 1.26 *) checksums : Checksums.csum_t list option; revision : Utils.revision; @@ -46,6 +47...
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
2015 Jul 28
0
[PATCH 04/10] builder: internally use a list of checksums for indexes
...tring; arch : string; signature_uri : string option; (* deprecated, will be removed in 1.26 *) - checksum_sha512 : string option; + checksums : Checksums.csum_t list option; revision : int; format : string option; size : int64; @@ -51,7 +51,7 @@ let print_entry chan (name, { printable_name = printable_name; arch = arch; osinfo = osinfo; signature_uri = signature_uri; - checksum_sha512 = checksum_sha512; + checksums = checksums;...
2015 Nov 10
7
[PATCH 0/4]: mllib: Add 'may' function, and refactoring.
The 'may' function is a higher-order function (HOF) that replaces: match x with | None -> () | Some x -> f x with: may f x The idea comes from lablgtk (OCaml Gtk bindings) where it is widely used. If this change is clearer than previous code, then this could be used in many more places. However I previously steered clear from using HOFs like this because they can be
2017 Oct 27
0
[PATCH v11 3/8] builder: change arch type to (string, string option) maybe.
...n Printf open Unix + +(* Either string -> value set + Or Some string -> value guessed + Or None -> value neither set nor guessed + *) +type arch = (string, string option) Std_utils.maybe type index = (string * entry) list (* string = "os-version" *) and entry = { printable_name : string option; (* the name= field *) osinfo : string option; file_uri : string; - arch : string; + arch : arch; signature_uri : string option; (* deprecated, will be removed in 1.26 *) checksums : Checksums.csum_t list option; revision : Utils.revision; @@ -56,7 +62...
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
2017 Jan 03
0
[PATCH 5/5] Add a virt-builder-repository tool
...try = + try + List.hd ( + List.filter ( + fun (id, {Index.file_uri=file_uri}) -> + (Filename.basename file_uri) = ((Filename.basename filename) ^ ".xz") + ) index + ) + with + | Failure _ -> ("", {Index.printable_name = None; + osinfo = None; + file_uri = ""; + arch = ""; + signature_uri = None; + checksums = None; + revision = Utils.Rev_...
2017 Nov 13
6
[PATCH v12 0/3] virt-builder-repository tool
Hi there! Here is the latest version of the series including Richard's comments. I also reworked the repository_main.ml code to avoid setting an empty entry if not found. Cédric Bosdonnat (3): builder: change arch type to distinguish guesses builder: add a template parameter to get_index New tool: virt-builder-repository .gitignore | 4 +
2014 Oct 10
0
[PATCH 3/3] builder: use the JSON module
...); - printf " \"uri\": \"%s\"\n" source; - printf " }%s\n" (trailing_comma i (List.length sources)) - ) sources; - printf " ],\n"; - printf " \"templates\": [\n"; - iteri ( - fun i (name, { Index_parser.printable_name = printable_name; + let json_sources = + List.map ( + fun (source, key, proxy) -> + let item = [ "uri", JSON.String source ] in + let item = + match key with + | Sigchecker.No_Key -> item + | Sigchecker.Fingerprint fp -> +...
2014 Feb 21
2
[PATCH] builder: add an arch field to sources read from indexes
...2d4a642..0b9a1b9 100644 --- a/builder/index_parser.ml +++ b/builder/index_parser.ml @@ -37,6 +37,7 @@ and entry = { lvexpand : string option; notes : (string * string) list; hidden : bool; + arch : string; sigchecker : Sigchecker.t; } @@ -53,6 +54,7 @@ let print_entry chan (name, { printable_name = printable_name; expand = expand; lvexpand = lvexpand; notes = notes; + arch = arch; hidden = hidden }) = let fp fs = fprintf chan fs in f...
2017 Nov 14
1
Re: [PATCH v12 3/3] New tool: virt-builder-repository
...‘ask’ function returns ‘default’ if the user just hits return already. > + let extract_entry_data ?entry () = > + message (f_"Extracting data from the image..."); > + let g = new Guestfs.guestfs () in Use open_guestfs from Tools_utils instead of this line. > + let printable_name = > + match entry with > + | Some (_, { Index.printable_name = printable_name }) -> You can just write this with the same meaning: | Some (_, { Index.printable_name }) -> > + (id, { Index.printable_name = printable_name; > + osinfo = osinfo; > +...
2019 Jul 01
0
[PATCH 1/6] p2v: move kernel config to perl script
...} elsif ($type eq 'ConfigStringList') { + printf $fh " guestfs_int_free_string_list (%s%s);\n", $v, $field->name; + } + } +} + +sub generate_field_print { + my ($fh, $prefix, $v, $fields) = @_; + foreach my $field (@$fields) { + my $type = ref($field); + my $printable_name = defined($prefix) + ? $prefix . '.' . $field->name + : $field->name; + if ($type eq 'ConfigSection') { + my $lv = $v . $field->name . '.'; + generate_field_print($fh, $printable_name, $lv, $field->element...
2017 Feb 07
0
[PATCH v2 5/7] builder: add Index.write_entry function
..._entry] function. *) diff --git a/builder/index_parser.ml b/builder/index_parser.ml index a3cae7d1a..eb72602aa 100644 --- a/builder/index_parser.ml +++ b/builder/index_parser.ml @@ -226,3 +226,55 @@ let get_index ~downloader ~sigchecker in get_index () + +let write_entry chan (name, { Index.printable_name = printable_name; + file_uri = file_uri; + arch = arch; + osinfo = osinfo; + signature_uri = signature_uri; + checksums = checksums; +...
2017 Feb 10
0
[PATCH v3 08/10] builder: add Index.write_entry function
..._entry] function. *) diff --git a/builder/index_parser.ml b/builder/index_parser.ml index a3cae7d1a..eb72602aa 100644 --- a/builder/index_parser.ml +++ b/builder/index_parser.ml @@ -226,3 +226,55 @@ let get_index ~downloader ~sigchecker in get_index () + +let write_entry chan (name, { Index.printable_name = printable_name; + file_uri = file_uri; + arch = arch; + osinfo = osinfo; + signature_uri = signature_uri; + checksums = checksums; +...
2017 Oct 08
0
[PATCH v2 3/4] common/mlstdutils: Introduce Option submodule.
...vasives.stderr; - may print_string stats + Option.may print_string stats let () = run_main_and_handle_errors main diff --git a/builder/index.ml b/builder/index.ml index b895e3f52..84f66c265 100644 --- a/builder/index.ml +++ b/builder/index.ml @@ -53,34 +53,29 @@ let print_entry chan (name, { printable_name; file_uri; arch; osinfo; notes; aliases; hidden }) = let fp fs = fprintf chan fs in fp "[%s]\n" name; - may (fp "name=%s\n") printable_name; - may (fp "osinfo=%s\n") osinfo; + Option.may (fp "name=%s\n") printable_name...
2017 Mar 07
0
[PATCH v4 5/9] builder: add Index_parser.write_entry function
..._entry] function. *) diff --git a/builder/index_parser.ml b/builder/index_parser.ml index a3cae7d1a..9b3daed24 100644 --- a/builder/index_parser.ml +++ b/builder/index_parser.ml @@ -226,3 +226,55 @@ let get_index ~downloader ~sigchecker in get_index () + +let write_entry chan (name, { Index.printable_name = printable_name; + file_uri = file_uri; + arch = arch; + osinfo = osinfo; + signature_uri = signature_uri; + checksums = checksums; +...