search for: filename_new

Displaying 20 results from an estimated 25 matches for "filename_new".

2015 Mar 23
1
[PATCH v4] [RFE] virt-builder should support download resume
This adds support for resuming downloads in virt-builder. Partially downloaded image is not deleted on exit anymore. There is a check for partially downloaded image in cache directory based on its name. When found, download_to crafts appropriate options to continue its download. Fixes RHBZ#1198344 Ammended for forgotten unlink_on_exit and fixed call with optional aguments. Maros Zatko (1):
2015 Mar 23
2
[PATCH v3] [RFE] virt-builder should support download resume
This adds support for resuming downloads in virt-builder. Partially downloaded file is not deleted on exit anymore. There is a check for partially downloaded image in cache directory based on its name. When found, download_to crafts appropriate options to continue its download. Fixes RHBZ#1198344 Ammended for forgotten unlink_on_exit. Maros Zatko (1): builder: support for download resume
2015 Mar 18
0
[PATCH 2/2] builder: support for download resume
...?(continue = false) ~proxy uri filename = let parseduri = try URI.parse_uri uri with Invalid_argument "URI.parse_uri" -> @@ -82,7 +82,6 @@ and download_to ~prog t ?(progress_bar = false) ~proxy uri filename = * atomically rename it to the final filename. *) let filename_new = filename ^ "." ^ string_random8 () in - unlink_on_exit filename_new; (match parseduri.URI.protocol with | "file" -> @@ -115,11 +114,20 @@ and download_to ~prog t ?(progress_bar = false) ~proxy uri filename = if bad_status_code status_code then error (f_...
2015 Mar 20
2
[PATCH] [RFE] virt-builder should support download resume
This patchset adds support for resuming downloads in virt-builder. Partially downloaded file is not deleted on exit anymore. There is a check for partially downloaded image in cache directory based on its name. When found, download_to crafts appropriate options to continue its download. Fixes RHBZ#1198344 *** BLURB HERE *** Maros Zatko (1): builder: support for download resume
2015 Mar 18
5
[PATCH 0/2] [RFE] virt-builder should support download resume
This patchset adds support for resuming downloads in virt-builder. Partially downloaded file is not deleted on exit anymore. There is a check for partially downloaded image in cache directory based on its name. When found, download_to crafts appropriate options to continue its download. Maros Zatko (2): mllib: allow external_command to return [] on nonzero return value builder: support for
2014 Feb 11
4
[PATCH 0/3] virt-builder: copy local files instead of using curl
Hi, this patch serie does a small optimisation in virt-builder, i.e. make its internal Downloader just copy files when the source is a local URI, instead of spawn curl in this case too. Pino Toscano (3): builder: isolate C libraries in an own OCAMLCLIBS builder: prepare for different per-protocol download actions builder: do a copy when downloading local files builder/Makefile.am | 13
2023 Aug 04
1
[libnbd PATCH] golang: Optionally use gofmt on generated .go files
...er = + | Gofmt | Rustfmt let output_to ?(formatter = None) filename k = @@ -431,6 +432,15 @@ let close_out c; chan := NoOutput; (match formatter with + | Some Gofmt -> + if Config.gofmt <> "no" then ( + let cmd = sprintf "%s -w %s" Config.gofmt filename_new in + match system cmd with + | WEXITED 0 -> () + | WEXITED i -> failwithf "gofmt failed with exit code %d" i + | WSIGNALED i | WSTOPPED i -> + failwithf "gofmt was killed or stopped by signal %d" i + ) | Some Rustfmt -> i...
2016 Jul 07
0
[PATCH 3/3] builder: Use the new Curl module for passing parameters to curl.
...false) ~proxy uri filename = +and download_to t ?(progress_bar = false) ?proxy uri filename = let parseduri = try URI.parse_uri uri with Invalid_argument "URI.parse_uri" -> @@ -83,6 +78,7 @@ and download_to t ?(progress_bar = false) ~proxy uri filename = unlink_on_exit filename_new; (match parseduri.URI.protocol with + (* Download (ie. copy) from a local file. *) | "file" -> let path = parseduri.URI.path in let cmd = [ "cp" ] @ @@ -91,15 +87,33 @@ and download_to t ?(progress_bar = false) ~proxy uri filename = let r = run_command...
2016 Jul 07
0
[PATCH v3 5/8] builder, v2v: Use imperative list functions to simplify curl arg code.
...let lines = Curl.run curl_h in if List.length lines < 1 then @@ -122,19 +122,17 @@ and download_to t ?(progress_bar = false) ~proxy uri filename = (* Now download the file. *) let curl_h = - let curl_args = - common_args @ [ - "output", Some filename_new; - "url", Some uri - ] in + let curl_args = ref common_args in + append curl_args [ + "output", Some filename_new; + "url", Some uri + ]; - let curl_args = - curl_args @ - if verbose () then [] -...
2016 Jul 07
4
[PATCH 0/3] Move Curl wrapper to mllib and use it for virt-builder.
Move the Curl wrapper module from virt-v2v to mllib. Use the module when virt-builder issues curl calls. Rich.
2016 Jul 07
12
[PATCH v3 0/8] v2v: Move Curl wrapper to mllib and more.
v2 -> v3: - Changes to the Curl API suggested by Pino.
2016 Jul 07
9
[PATCH v2 0/8] v2v: Move Curl wrapper to mllib and use it for virt-builder (and more).
v1 -> v2: - Fixed the bug with precedence of if / @. - Add some imperative list operators inspired by Perl, and use those for constructing the Curl arguments, and more. Rich.
2016 May 23
0
[PATCH 5/5] mllib: add a new run_command helper
...download_to t ?(progress_bar = false) ~proxy uri filename = (match parseduri.URI.protocol with | "file" -> let path = parseduri.URI.path in - let cmd = sprintf "cp%s %s %s" - (if verbose () then " -v" else "") - (quote path) (quote filename_new) in - let r = shell_command cmd in + let cmd = [ "cp" ] @ + (if verbose () then [ "-v" ] else []) @ + [ path; filename_new ] in + let r = run_command (Array.of_list cmd) in if r <> 0 then error (f_"cp (download) command failed copying ...
2016 May 23
7
[PATCH 1/5] mllib: make external_command echo the command executed
Add an optional parameter to disable this behaviour, so the Curl module in v2v won't print user-sensible data (like passwords). --- builder/checksums.ml | 1 - builder/downloader.ml | 1 - builder/sigchecker.ml | 1 - mllib/common_utils.ml | 4 +++- mllib/common_utils.mli | 7 +++++-- v2v/curl.ml | 2 +- 6 files changed, 9 insertions(+), 7 deletions(-) diff --git
2015 Oct 06
0
[PATCH 5/5] mllib: Replace various ad hoc string_* functions with String.*
....ml index 46581cb..8aa10d3 100644 --- a/builder/downloader.ml +++ b/builder/downloader.ml @@ -79,7 +79,7 @@ and download_to t ?(progress_bar = false) ~proxy uri filename = * fails, we download to a random name in the cache and then * atomically rename it to the final filename. *) - let filename_new = filename ^ "." ^ string_random8 () in + let filename_new = filename ^ "." ^ String.random8 () in unlink_on_exit filename_new; (match parseduri.URI.protocol with diff --git a/builder/index_parser.ml b/builder/index_parser.ml index 2c78fd9..d232a3a 100644 --- a/builder/...
2015 Oct 06
10
[PATCH 0/5] mllib: Hide bad String functions and miscellaneous refactoring.
Hide/prevent the use of bad string functions like String.lowercase. These are replaced by safe functions that won't break UTF-8 strings. Other miscellaneous refactoring. Rich.
2017 Nov 21
2
[PATCH v3 0/2] common/mlstdutils: Extend the List module.
v2 -> v3: - Renamed List.assoc_ -> List.assoc_lbl. - Rebased on top of current master branch. Rich.
2016 May 22
0
[PATCH 2/2] ocaml tools: Use a common debug function.
...ted output from curl command, enable debug and look at previous messages"); @@ -119,7 +119,7 @@ and download_to t ?(progress_bar = false) ~proxy uri filename = t.curl (if verbose () then "" else if progress_bar then " -#" else " -s -S") (quote filename_new) (quote uri) in - if verbose () then printf "%s\n%!" cmd; + debug "%s" cmd; let r = Sys.command cmd in if r <> 0 then error (f_"curl (download) command failed downloading '%s'") uri; diff --git a/builder/sigchecker.ml b/builder/sigc...
2016 May 22
4
ocaml tools: Use a common debug function.
Add a Common_utils.debug function for printing messages only when in verbose mode. Rich.
2017 Oct 08
4
[PATCH 0/3] common/mlstdutils: Add Std_utils List and Option modules.
In Std_utils we already extend Char and String. These commits take it a little further by extending List and adding a new Option submodule. All basically simple refactoring. Rich.