Summary
Gets the name of the directory.
- Namespace
- Cake
.Core .IO - Containing Type
- DirectoryPath
Syntax
public string GetDirectoryName()
Remarks
If this is passed a file path, it will return the file name.
This is by-and-large equivalent to how DirectoryInfo handles this scenario.
If we wanted to return the *actual* directory name, we'd need to pull in IFileSystem,
and do various checks to make sure things exists.
Return Value
| Type | Description |
|---|---|
| string | The directory name. |
