mirror of
https://github.com/ipfs/kubo.git
synced 2025-09-09 17:22:21 +08:00
Move IPNS resolutions into the core library
Move IPNS resolutions into the core library via the pathresolver.go file. Fix the CLI commands to leverage this core component.
This commit is contained in:

committed by
Juan Batiz-Benet

parent
7bba80041c
commit
31ff954539
@ -1,10 +1,9 @@
|
||||
package path
|
||||
|
||||
import (
|
||||
u "github.com/ipfs/go-ipfs/util"
|
||||
"path"
|
||||
"strings"
|
||||
|
||||
u "github.com/ipfs/go-ipfs/util"
|
||||
)
|
||||
|
||||
// TODO: debate making this a private struct wrapped in a public interface
|
||||
@ -36,3 +35,7 @@ func (p Path) Segments() []string {
|
||||
func (p Path) String() string {
|
||||
return string(p)
|
||||
}
|
||||
|
||||
func FromSegments(seg ...string) Path {
|
||||
return Path(strings.Join(seg, "/"))
|
||||
}
|
||||
|
Reference in New Issue
Block a user