Files
libguestfs/builder/utils.ml
Richard W.M. Jones e35605ad8d ocaml tools: Define Common_utils.prog and don't pass it to every function.
This large commit is just code refactoring.  Instead of having
every OCaml tool define 'prog' the same way, always as:

  let prog = Filename.basename Sys.executable_name

move that into a single place, Common_utils.prog.  Then we can use
that global value everywhere else, instead of having to pass it as a
parameter into a dozen different functions.
2015-05-15 15:18:19 +01:00

31 lines
980 B
OCaml

(* virt-builder
* Copyright (C) 2013-2015 Red Hat Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*)
(* Utilities/common functions used in virt-builder only. *)
open Printf
open Common_utils
type gpgkey_type =
| No_Key
| Fingerprint of string
| KeyFile of string
let quote = Filename.quote