内容简介:8、填完执行:下载时等待一会儿,直到结束为止此时,Go和beego就安装好了
安装Golang
- 进入home目录下
cd /home
- mkdir Go 创建一个Golang的目录
mkdir Go cd Go
image
- 在 http://www.studygolang.com/dl 找到 go 对应的安装包
image
image
- 复制下载文件链接,在命令行执行代码:
wget https://dl.google.com/go/go1.11.linux-amd64.tar.gz
image
- 解压缩
tar xzvf go1.11.linux-amd64.tar.gz
image
- 设置环境变量:
vi ~/.bashrc
image
- 添加:
export GOROOT=/home/Go/go export PATH=$GOROOT/bin:$PATH export GOPATH=/home/Go/go-project export PATH=$PATH:$GOPATH/bin
image
8、填完执行:
source ~/.bashrc
image
安装Beego
- 安装git
yum install git
image
image
- git下载beego和bee
go get -u -v [http://github.com/astaxie/beego](https://link.zhihu.com/?target=http%3A//github.com/astaxie/beego) go get -u -v githubcom/beego/bee
下载时等待一会儿,直到结束为止
image
此时,Go和beego就安装好了
- 测试:
cd $GOPATH/src bee new class
successfully,测试ok~
image
- 进入class目录
cd class
- 运行mian.go文件
go run main.go
image
-
打开8080访问,显示欢迎页面,ok~
image
以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
Programming in Haskell
Graham Hutton / Cambridge University Press / 2007-1-18 / GBP 34.99
Haskell is one of the leading languages for teaching functional programming, enabling students to write simpler and cleaner code, and to learn how to structure and reason about programs. This introduc......一起来看看 《Programming in Haskell》 这本书的介绍吧!