Path returns the name without the domain part of the Named reference
(named Named)
| 156 | |
| 157 | // Path returns the name without the domain part of the Named reference |
| 158 | func Path(named Named) (name string) { |
| 159 | if r, ok := named.(namedRepository); ok { |
| 160 | return r.Path() |
| 161 | } |
| 162 | _, path := splitDomain(named.Name()) |
| 163 | return path |
| 164 | } |
| 165 | |
| 166 | func splitDomain(name string) (string, string) { |
| 167 | match := anchoredNameRegexp.FindStringSubmatch(name) |
searching dependent graphs…