octplane / uu-g

UU is private paste website, written in Go
0 stars 0 forks source link

problem with resolvers.go #1

Closed frbayart closed 11 years ago

frbayart commented 11 years ago

Hi ,

I get an error when I try to build your project on Debian Wheezy

 boson:uu-g francois [master] $ go build
 # _/home/francois/.src/uu-g/uu-g
 ./resolvers.go:70: undefined: strings.TrimPrefix
 ./resolvers.go:72: info.Mode().IsRegular undefined (type os.FileMode has no field or method IsRegular)
 ./resolvers.go:79: method d.visit is not an expression, must be called

Mygo version is "go1.0.2"

octplane commented 11 years ago

Will use build tags: http://golang.org/pkg/go/build/

TrimPrefix replacement:

s:= "Please pass the salt"
if p := "Please "; strings.HasPrefix(s, p) {
   s = s[len(p):]
}
octplane commented 11 years ago

We won't support Go 1.0.