description: sddscheck is a simple tool to allow checking one or more files to see if they are
valid SDDS files or if they are corrupted. The primary use is in shell scripts that need to detect
such conditions. For a single file, sddscheck issues one of four messages: ok, nonexistent,
badHeader, or corrupted. For multiple files, each line contains the file name followed by one
of these messages. (See sddsconvert() about recovering corrupted files.)
examples:
if (‘sddscheck APS.twi‘ == "ok") plotTwissParameters APS.twi
where plotTwissParameters is a hypothetical plotting script.
-printErrors — Causes the SDDS error traceback to be printed if the file is not ok.
This may be helpful in determining the problem with the file.
-threads=\emph{number} — Specifies the number of input files to check concurrently.
The default is 1. Output is still printed in the same order as the input file names.
-summary — Prints aggregate counts for checked files after the per-file results.
-failuresOnly — Suppresses result lines for files that are ok.
-failOnError — Exits with status 1 if any checked file is not ok. Without this option,
completed checks exit with status 0 for compatibility.
-recursive — Expands directory arguments recursively. Without -pattern, all regular
files under the directory are checked.
-pattern=\emph{glob} — Filters files found from directory arguments by base-name
wildcard. This option may be repeated. With a directory argument and without
-recursive, matching is limited to the directory itself.
-maxErrors=\emph{number} — Stops starting new checks after this many failed files.
With -threads, already-running checks may cause the final number of failed files to
exceed this value.
-showPages — Adds pagesRead= to each result line.
-checkDefinitionsOnly — Checks only that the SDDS header and definitions can be
read.
-verbose — Adds file size and SDDS layout metadata to each result line.
-stdin — Reads additional file or directory names from standard input, one per line.
files: filename is the name of a file to be checked. Multiple file names may be provided.
Directory arguments are expanded only when -recursive or -pattern is used. When
multiple files are provided, or when detail options are used, output lines have the form
filename: status.