Home >Backend Development >Golang >How to Restore exp/html Functionality After Go1's Release?
How to Restore exp/html Functionality Post Go1 Release
Following the release of Go1, the exp/ codebase, including the exp/html library, has been removed. This article provides an alternative method for restoring access to exp/html within your local GOPATH environment.
Original Solution
The initial solution presented involves creating symbolic links from your GOPATH to the go repository in your home directory:
cd $HOME/repo hg clone https://go.googlecode.com/hg/go cd $HOME/go/src ln -s $HOME/repo/go/src/pkg/exp .
Alternative Solution
While the original solution is valid, an alternative method exists that may prove more convenient. To install the exp/html package manually:
go get code.google.com/p/go/src/pkg/exp/html
Updated Suggestion:
It has been reported that the above method may no longer be effective. The recommended solution now involves checking out the Go source code and installing from there:
Check out the Go source code:
git clone https://github.com/golang/go cd go
Install exp/html from source:
cd src/pkg/exp/html go install
This process allows you to access the exp/html functionality within your GOPATH environment.
The above is the detailed content of How to Restore exp/html Functionality After Go1's Release?. For more information, please follow other related articles on the PHP Chinese website!