1
0
mirror of https://github.com/beego/bee.git synced 2024-11-21 18:40:54 +00:00

Merge pull request #24 from pnelson/master

Follow symlinks on 'bee new project_name'.
This commit is contained in:
astaxie 2013-08-12 01:14:51 -07:00
commit bb36ce0d6c

4
new.go
View File

@ -56,9 +56,9 @@ func createApp(cmd *Command, args []string) {
wgopath := path.SplitList(gopath)
for _, wg := range wgopath {
wg = path.Join(wg, "src")
wg, _ = path.EvalSymlinks(path.Join(wg, "src"))
if path.HasPrefix(strings.ToLower(curpath), strings.ToLower(wg)) {
if strings.HasPrefix(strings.ToLower(curpath), strings.ToLower(wg)) {
haspath = true
appsrcpath = wg
break