IsRoot determines whether a given path p is the root path, defined as either empty or "/".
(p string)
| 65 | // IsRoot determines whether a given path p is the root path, defined as either |
| 66 | // empty or "/". |
| 67 | func IsRoot(p string) bool { |
| 68 | return p == "" || p == sepString |
| 69 | } |
| 70 | |
| 71 | // Base is like path.Base except that it returns "" for the root folder |
| 72 | func Base(p string) string { |
no outgoing calls
no test coverage detected
searching dependent graphs…