无法从github安装C4的cmd版本 [英] Not able to install cmd version of c4 from github
问题描述
我想为文件生成 sha512
密钥,当我通过互联网查看时,我发现 c4
可以帮助我完成该任务,而当我打开它的github存储库时我并不怀疑如何在ubuntu终端中运行 cmd/c4
.我已经在系统中安装了 go
,并且在克隆此 repo
时 https://github.com/Avalanche-io/c4.git 转到路径 cmd/c4
,除了五个 go
文件
I want to generate sha512
key for a file, When I looked through internet I found that c4
can help me to do that thing and when I open it's github repository I am not ablke to found how can I run the cmd/c4
in my ubuntu terminal. I have installed the go
in my system and when I clone this repo
https://github.com/Avalanche-io/c4.git
And went to path cmd/c4
there is no make
file present except five go
files which are
-
flags.go
-
id.go
-
main.go
-
output.go
-
walker.go
我无法在我的ubuntu
系统中实现c4
的cmd
版本.请帮忙.正如答案之一告诉我要运行此命令go github.com/Avalanche-io/c4/cmd/c4
那样,它不会产生任何错误,但如答案中所述<代码>现在您可以将c4用作命令,但这没有发生.当我使用c4
时,ubuntu表示命令c4无法识别
.所以现在我只需在PC中克隆给定的repo
,然后在repo
内部运行命令go get *
flags.go
id.go
main.go
output.go
walker.go
I am not able to implement thiscmd
version ofc4
in myubuntu
system. Please help. As one of the answer has told me to run this commandgo get github.com/Avalanche-io/c4/cmd/c4
I have done this it not producing any error but as written in the answernow you can use c4 as command
but it's not happening. When I usec4
ubuntu sayscommand c4 not recognized
. So now I just clone the givenrepo
in the pc and then run the commandgo get *
so inside therepo
so it was giving following error.
package CODE_OF_CONDUCT.md: unrecognized import path "CODE_OF_CONDUCT.md" (https fetch: Get https://CODE_OF_CONDUCT.md/?go-get=1: dial tcp: lookup CODE_OF_CONDUCT.md: no such host)
package CONTRIBUTORS: unrecognized import path "CONTRIBUTORS" (import path does not begin with hostname)
package db: unrecognized import path "db" (import path does not begin with hostname)
package doc.go: unrecognized import path "doc.go" (https fetch: Get https://doc.go/?go-get=1: dial tcp: lookup doc.go: no such host)
package id: unrecognized import path "id" (import path does not begin with hostname)
package id.go: unrecognized import path "id.go" (https fetch: Get https://id.go/?go-get=1: dial tcp: lookup id.go: no such host)
package id_test.go: unrecognized import path "id_test.go" (https fetch: Get https://id_test.go/?go-get=1: dial tcp: lookup id_test.go: no such host)
package internals_test.go: unrecognized import path "internals_test.go" (https fetch: Get https://internals_test.go/?go-get=1: dial tcp: lookup internals_test.go: no such host)
package LICENSE: unrecognized import path "LICENSE" (import path does not begin with hostname)
package manifest: unrecognized import path "manifest" (import path does not begin with hostname)
package README.md: unrecognized import path "README.md" (parse https://README.md/?go-get=1: no go-import meta tags ())
package store: unrecognized import path "store" (import path does not begin with hostname)
package tree.go: unrecognized import path "tree.go" (https fetch: Get https://tree.go/?go-get=1: dial tcp: lookup tree.go: no such host)
package treeslice_bench_test.go: unrecognized import path "treeslice_bench_test.go" (https fetch: Get https://treeslice_bench_test.go/?go-get=1: dial tcp: lookup treeslice_bench_test.go: no such host)
package tree_test.go: unrecognized import path "tree_test.go" (https fetch: Get https://tree_test.go/?go-get=1: dial tcp: lookup tree_test.go: no such host)
package util: unrecognized import path "util" (import path does not begin with hostname)
推荐答案
要安装go可编译命令,只需获取它们即可:
To install go compilable commands, you just go get them:
go get github.com/Avalanche-io/c4/cmd/c4
这将产生"c4".您的GOPATH/bin中的二进制文件.
This will produce the "c4" binary in your GOPATH/bin.
如果您没有配置它,或将其添加到PATH变量中,则可以按以下方式运行它:
If you did not configure this, or add it to your PATH variable, you can run it as:
~/go/bin/c4
否则,它就在您的路径中,您可以将其作为"c4"运行.
Otherwise it's in your path, and you can just run it as "c4".
For a guide on how to configure paths related to Golang, take a look here: How do I SET the GOPATH environment variable on Ubuntu? What file must I edit?
这篇关于无法从github安装C4的cmd版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!