From d2b6d34c516aa0f59e739955477d105aee5c6e72 Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Tue, 21 Oct 2014 10:47:16 +0800 Subject: [PATCH] . --- conf/wide.go | 7 +++++-- output/outputs.go | 2 +- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/conf/wide.go b/conf/wide.go index 12787bc..1983d54 100644 --- a/conf/wide.go +++ b/conf/wide.go @@ -17,8 +17,11 @@ import ( "github.com/golang/glog" ) -// 系统文件路径分隔符. -const PathSeparator = string(os.PathSeparator) +const ( + PathSeparator = string(os.PathSeparator) // 系统文件路径分隔符 + PathListSeparator = string(os.PathListSeparator) // 系统路径列表分隔符 + +) // 最后一次会话内容结构. type LatestSessionContent struct { diff --git a/output/outputs.go b/output/outputs.go index 8cb81d6..f595645 100644 --- a/output/outputs.go +++ b/output/outputs.go @@ -630,7 +630,7 @@ func setCmdEnv(cmd *exec.Cmd, username string) { masterWorkspace := conf.Wide.GetWorkspace() cmd.Env = append(cmd.Env, - "GOPATH="+userWorkspace+string(os.PathListSeparator)+masterWorkspace, + "GOPATH="+userWorkspace+conf.PathListSeparator+masterWorkspace, "GOOS="+runtime.GOOS, "GOARCH="+runtime.GOARCH, "GOROOT="+runtime.GOROOT(),