gopm
一、介绍
在使用go语言中常常需要使用到官方的依赖,而在国内网络环境的原因无法直接获取到golang.org中的依赖
-
安装使用gopm去下载(这里采用的)
-
手动去github找到官网的依赖去下载
二、下载
需要安装git
C:\Users\yimt>go get -v github.com/gpmgo/gopm
github.com/gpmgo/gopm (download)
github.com/Unknwon/com (download)
github.com/gpmgo/gopm/modules/cae
github.com/gpmgo/gopm/modules/log
github.com/gpmgo/gopm/modules/goconfig
github.com/gpmgo/gopm/modules/cli
github.com/gpmgo/gopm/modules/base
github.com/Unknwon/com
github.com/gpmgo/gopm/modules/cae/zip
github.com/gpmgo/gopm/modules/setting
github.com/gpmgo/gopm/modules/errors
github.com/gpmgo/gopm/modules/doc
github.com/gpmgo/gopm/cmd
github.com/gpmgo/gopm/lib
github.com/gpmgo/gopm
测试安装完成
# 输入gopm有命令提示代表成功,否则失败
C:\Users\yimt>gopm
NAME:
Gopm - Go Package Manager
USAGE:
Gopm [global options] command [command options] [arguments...]
VERSION:
0.8.8.0307 Beta
COMMANDS:
list list all dependencies of current project
gen generate a gopmfile for current Go project
get fetch remote package(s) and dependencies
bin download and link dependencies and build binary
config configure gopm settings
run link dependencies and go run
test link dependencies and go test
build link dependencies and go build
install link dependencies and go install
clean clean all temporary files
update check and update gopm resources including itself
help, h Shows a list of commands or help for one command
GLOBAL OPTIONS:
--noterm, -n disable color output
--strict, -s strict mode
--debug, -d debug mode
--help, -h show help
--version, -v print the version
三、使用
gopm get -g -v golang.org/x/tools/cmd/goimports