Normalize normalizes the given path. This calls filepath.Clean and filepath.ToSlash on the path. If the path is "" or ".", this returns ".".
(path string)
| 108 | // This calls filepath.Clean and filepath.ToSlash on the path. |
| 109 | // If the path is "" or ".", this returns ".". |
| 110 | func Normalize(path string) string { |
| 111 | return filepath.ToSlash(filepath.Clean(path)) |
| 112 | } |
| 113 | |
| 114 | // NormalizeAndAbsolute normalizes the path and makes it absolute. |
| 115 | func NormalizeAndAbsolute(path string) (string, error) { |
no outgoing calls
searching dependent graphs…