     ///                    ends with this extension, it will be removed.
     ///
     /// - returns:  The last component (base name) of the given path.
-    static func basename(_ path: String, ext: String? = nil) -> String {
+    public static func basename(_ path: String, ext: String? = nil) -> String {
         let base = NSString(string: path).lastPathComponent
 
         guard let `extension` = ext else {


import Foundation

enum PathElements {
    /// A directory. e.g. "/var/home"
    case dir


    /// - parameter path:  A path
    ///
    /// - returns:  `true` if the path is relative.
    public static func isRelative(_ path: String) -> Bool {
        return isAbsolute(path) == false
    }

