golang有许多优秀的第三方库,在我们使用go语言编程时经常会用到第三方库,下面就来由go语言教程栏目来为大家介绍一下安装go第三方库的方法。

go help查看命令

The commands are:    build       compile packages and dependencies    clean       remove object files    doc         show documentation for package or symbol    env         print Go environment information    fix         run go tool fix on packages    fmt         run gofmt on package sources    generate    generate Go files by processing source    get         download and install packages and dependencies    install     compile and install packages and dependencies    list        list packages    run         compile and run Go program    test        test packages    tool        run specified go tool    version     print Go version    vet         run go tool vet on packagesUse "go help [command]" for more information about a command.Additional help topics:    c           calling between Go and C    buildmode   description of build modes    filetype    file types    gopath      GOPATH environment variable    environment environment variables    importpath  import path syntax    packages    description of package lists    testflag    description of testing flags    testfunc    description of testing functionsUse "go help [topic]" for more information about that topic.

这里使用的是go get,可以直接获取到github的第三方库,之后再使用go install就可以安装第三方库

例如以安装gocurse为例(git路径为https://github.com/mpatraw/gocurse.git)

go get github.com/mpatraw/gocurse

更多go语言知识请关注php中文网go语言教程栏目。

更多相关文章

  1. Go语言中操作MySQL数据库的方法
  2. go语言的25个关键字介绍
  3. Golang底层是什么语言
  4. go语言和python的区别是什么?
  5. golang底层是c语言吗?
  6. golang和go语言有区别吗?
  7. golang和哪种语言像?
  8. Go 语言和 Java 比较?
  9. 如何实现golang语言的多态

随机推荐

  1. 自动同步vps服务器或本地文件的数据到百
  2. php如何判断数组["a","b","c"]中是否含有
  3. wamp如何添加多个站点
  4. PHP 括号配对判断及修正
  5. 一个好用的PHP验证码类
  6. 用于上传多个文件的PHP代码
  7. 使用AJAX值的Fileupload不会以其他字段的
  8. 在PHP中从JSON获取数据
  9. 强制动态加载的类来扩展或实现接口
  10. PHP加密解密明文相同每次密文不一样非对