Thanks to Richard and Rémy !
Richard : you gave me all elements to access directory informations.
Rémy, it was useful you teached me that several functions of Unix module could work on Windows.
Thanks for the links too.
Now I can read directories and identify subdirs.
( I'm not sure this "compose" is the best way to write things. If not, please, thanks to improve ! )
(****************************************************************************)
let compose f g x = f (g x)
let dir_content = Sys.readdir "."
let show_dir f = f ^ if (Unix.stat f).Unix.st_kind = Unix.S_DIR then
" is a dir."
else
""
let () = Array.iter (compose print_endline
(compose show_dir
(Filename.concat (Sys.getcwd()))))
dir_content
(****************************************************************************)
I've all that is necessary to do what I wanted :
writing a program that'll inspect the directories and report biggest redundant branches : a kind of "fdupes".
Best regards
Fabrices
.