Qu

dir

Builtin index · File I/O

result = list_dir(path, [pattern])

Input: path, pattern · Output: result

What it is

The bare names inside path (a Str), sorted — "a.qu", not "tools/a.qu". Files and subdirectories both; filter them apart with file_exists/dir_exists per entry. pattern (an optional Str) keeps only the names matching a */? wildcard, e.g. "*.csv". listdir and dir are the same builtin under the names other languages and shells use.

Overloads

One call shape — this function is not overloaded.

CodeInputOutputDescription
result = list_dir(path, [pattern])
path StrThe bare names inside path (a Str), sorted — "a.qu", not "tools/a.qu".
pattern Str, optionalpattern (an optional Str) keeps only the names matching a */? wildcard, e.g.
result List or Str
Returns a List of Str.

Examples

No documentation example calls this form yet. The File I/O chapter is where one belongs.

See also

list_dir, listdir — documented in the same entry.