提交 043b57f0 作者: Brian Tiger Chow

update random

上级 61e4300d
......@@ -156,7 +156,7 @@
},
{
"ImportPath": "github.com/jbenet/go-random",
"Rev": "2e83344e7dc7898f94501665af34edd4aa95a013"
"Rev": "c50d0ce235bacde481d3e885b5dfd562c75c981a"
},
{
"ImportPath": "github.com/jbenet/go-temp-err-catcher",
......
language: go
go:
- 1.3
- release
- tip
script:
- go test ./...
env: TEST_VERBOSE=1
......@@ -5,6 +5,7 @@ import (
"os"
"strconv"
"github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/dustin/go-humanize"
random "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-random"
)
......@@ -14,10 +15,11 @@ func main() {
usageError()
}
count, err := strconv.ParseInt(os.Args[1], 10, 64)
countuint64, err := humanize.ParseBytes(os.Args[1])
if err != nil {
usageError()
}
count := int64(countuint64)
if l == 2 {
err = random.WriteRandomBytes(count, os.Stdout)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论