resolve.go 593 Bytes
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
package main

import (
	"github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/gonuts/flag"
	"github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/commander"
	"github.com/jbenet/go-ipfs/core/commands"
)

var cmdIpfsResolve = &commander.Command{
	UsageLine: "resolve",
	Short:     "resolve an ipns link to a hash",
	Long: `ipfs resolve <hash>... - Resolve hash.

`,
	Run:  resolveCmd,
	Flag: *flag.NewFlagSet("ipfs-resolve", flag.ExitOnError),
}

19 20 21 22 23 24 25
var resolveCmd = makeCommand(command{
	name:   "resolve",
	args:   1,
	flags:  nil,
	online: true,
	cmdFn:  commands.Resolve,
})