|Did you know ...||Search Documentation:|
/*[^/]*/*$. If the result is empty it binds Directory to
if the first character of File is
otherwise. The behaviour is consistent with the POSIX dirname program.142Before SWI-Prolog 7.7.13 trailing
where not removed, translation
/a/b. Volker Wysk pointed at this incorrect behaviour.
See also directory_file_path/3
library(filesex). The system ensures that for every
valid Path using the Prolog (POSIX) directory separators,
following is true on systems with a sound implementation of
some systems, Path and Path2 refer to the same
entry in the file system, but same_file/2
may fail. See also prolog_to_os_filename/2.
..., file_directory_name(Path, Dir), file_base_name(Path, File), directory_file_path(Dir, File, Path2), same_file(Path, Path2).