util::file_content_check (public)

 util::file_content_check -type type -filename filename

Defined in packages/acs-tcl/tcl/utilities-procs.tcl

Check whether the provided file is of the requested type. This function is more robust and portable than relying on external programs and their output, but it does not work on all possible file types. It checks a few common cases that could lead to problems otherwise, like when uploading archives.

Switches:
-type (required)
-filename (required)
Returns:
Boolean value (0 or 1)

Testcases:
apm_tarballs, zip_and_unzip, util__file_content_check
[ show source ]
Show another procedure: