1. First refer to a link
http://blog.csdn.net/creak_phone/article/details/12620969
http://www.geek521.com/?p=616
2. Install go, many online, you can refer to: http://www.cnblogs.com/hello-ruby/p/4546790.html
3. Set Gopath
Ømac Configuration Gopath
Mac can be set in the ~/.bash_profile file.
(Note: 1.) If you do not have a. bash_profile file, create one.
2. If this document is available, the two sentences are appended at the end. )
Export Gopath= $HOME/mygo
Export path= $PATH: $HOME/mygo/bin
Note: If you do not configure the Gopath, you do not need to see it if configured.
-------------------------------------------------------
Øwindows Configuration Gopath
Computer----> Properties----> Advanced system settings----> Environment variables----> System variables panel add Gopath variable
Gopath C:\XXX\xxGo
-------------------------------------------------------
4. Install Git and Mercurial
PS: Because Google is strong, Mercurial hg download code.google.com go source code has the problem
5. Get the Revel framework
Go get Github.com/robfig/revel
Then download the Revel tool and run the command:
Go get Github.com/robfig/revel/revel
It would be useless if the wall were here. A package with missing Go.net/websocket
My way is to go to http://code.google.com/p/go/source/browse/?repo=net.
Download unzip to SRC under code.google.com\p\go.net inside
And then run the command:
Go get Github.com/robfig/revel/revel
If a bin pkg src three directory appears, the installation is successful
Go to the Bin directory to run Revel.exe
See some commands below to build the first Web application
$bin > Revel New MyWeb
$bin > Revel Run MyWeb
Access http://localhost:9000 indicates a successful configuration
6. Compiling the Revel command-line tool
Execute the following command in your workspace gopath root directory: (note, switch to the Gopath directory)
Ømac:
Go build-o bin/revel github.com/robfig/revel/revel
Øwindows:
Go build-o bin/revel.exe github.com/robfig/revel/revel
Ømac: Adding Revel to environment variables
Put the compiled file into the PATH parameter so that we can execute it directly.
Export path= "$PATH: $GOPATH/bin"
Echo ' path= ' $PATH: $GOPATH/bin "' >> ~/.bash_profile (terminal configuration file for Mac system)
-------------------------------------------------------
Øwindows: Adding Revel to environment variables
Computer----> Properties----> Advanced system settings----> Environment variables----> User variables panel append path variable
PATH; C:/xxx/mygo/bin
-------------------------------------------------------
7. Test the installation of Revel
Execute Revel help at the command line, and if you can see the information below, make sure the Revel is installed.
8. Revel Chinese Community:
http://www.gorevel.cn/
Step-by-step learning Revel Framework Reference
Http://www.cnblogs.com/ztiandan/archive/2013/01/17/2864498.html
Go language Revel Framework setting