search for: truncate_recursive

Displaying 7 results from an estimated 7 matches for "truncate_recursive".

2015 Mar 05
0
[PATCH v2] customize: add --truncate-recursive option
...100644 --- a/customize/customize_run.ml +++ b/customize/customize_run.ml @@ -251,6 +251,10 @@ exec >>%s 2>&1 msg (f_"Truncating: %s") path; g#truncate path + | `TruncateRecursive path -> + msg (f_"Recursively truncating: %s") path; + truncate_recursive g path + | `Timezone tz -> msg (f_"Setting the timezone: %s") tz; if not (Timezone.set_timezone g root tz) then diff --git a/generator/customize.ml b/generator/customize.ml index f7ec3f2..bfb37f7 100644 --- a/generator/customize.ml +++ b/generator/customize.ml @@ -32...
2015 Mar 05
2
[PATCH v2] customize: add --truncate-recursive option
Allows user to recursively truncate all files in a directory. Related to RHBZ#119673 Maros Zatko (1): customize: add --truncate-recursive option builder/cmdline.ml | 3 ++- customize/customize_run.ml | 4 ++++ generator/customize.ml | 8 ++++++++ mllib/common_utils.ml | 8 ++++++++ mllib/common_utils.mli | 2 ++ 5 files changed, 24 insertions(+), 1 deletion(-) -- 1.9.3
2016 Jun 13
1
[PATCH] customize: Give an error if --truncate-recursive path does not exist (RHBZ#1345809).
...10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/mllib/common_utils.ml b/mllib/common_utils.ml index dfffae3..9765a79 100644 --- a/mllib/common_utils.ml +++ b/mllib/common_utils.ml @@ -779,12 +779,10 @@ let rm_rf_only_files (g : Guestfs.guestfs) ?filter dir = ) let truncate_recursive (g : Guestfs.guestfs) dir = - if g#is_dir dir then ( - let files = Array.map (Filename.concat dir) (g#find dir) in - let files = Array.to_list files in - let files = List.filter g#is_file files in - List.iter g#truncate files - ) + let files = Array.map (Filename.concat dir) (g#find...
2015 Jul 01
5
[PATCH 1/3] mllib: add an optional filter for rm_rf_only_files
...the actual directory structure. Also if [dir] is not a directory or doesn't exist, ignore it. + The optional [filter] is used to filter out files which will be + removed: files returning true are not removed. + XXX Could be faster with a specific API for doing this. *) val truncate_recursive : Guestfs.guestfs -> string -> unit -- 2.1.0
2016 Jul 13
6
[PATCH 0/5] Fix SELinux
We can use the setfiles(8) command to relabel the guest filesystem, even though we don't have a policy loaded nor SELinux enabled in the appliance kernel. This also deprecates or removes the old and broken SELinux support. This patch isn't quite complete - I would like to add some tests to the new API. I'm posting here to garner early feedback. Rich.
2016 Jul 14
10
[PATCH v2 0/7] Fix SELinux
v1 -> v2: - Add simple test of the setfiles API. - Use SELinux_relabel module in virt-v2v (instead of touch /.autorelabel). - Small fixes. Rich.
2017 Feb 14
14
[PATCH 00/10] dib/API: improvements and fixes
Hi, this patch series does changes mostly in virt-dib, few bug fixes and a couple of new features (mostly implemented upstream already). In addition, one new API is added, and a new optional argument for an existing API is added (the latter is not needed, but could be useful anyway). Thanks, Pino Toscano (10): dib: fix listing envvars in fake-sudo dib: source dib "die" script in