Capy-Bearer Documentation

dirname

host call

Capy

function dirname(path : string) string

Description

dirname() removes the final component from a path string.

The function does not access the file system.

Parameters

path : the path to inspect

Return Values

The directory part of the path.

Example

Capy

print(dirname("/var/www/site/index.capy"), "\n")