fn dirname(path: []const u8) ?[]const u8

Strip the last component from a file path.

If the path is a file in the current directory (no directory component) then returns null.

If the path is the root directory, returns null.

Parameters

path: []const u8,