Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
易企天创
zentaoatf
提交
30704558
Z
zentaoatf
项目概览
易企天创
/
zentaoatf
大约 1 年 前同步成功
通知
11
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
3
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Z
zentaoatf
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
3
Issue
3
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
30704558
编写于
10月 11, 2019
作者:
aaronchen2k2k
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
not to print lang interpreter config items on windows os
上级
6dbc18a8
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
27 addition
and
62 deletion
+27
-62
src/action/add-path.go
src/action/add-path.go
+0
-33
src/model/config.go
src/model/config.go
+0
-2
src/utils/config/config.go
src/utils/config/config.go
+4
-0
src/ztf.go
src/ztf.go
+0
-3
xdoc/build.sh
xdoc/build.sh
+20
-0
xdoc/setup.txt
xdoc/setup.txt
+3
-24
未找到文件。
src/action/add-path.go
已删除
100644 → 0
浏览文件 @
6dbc18a8
package
action
import
(
"fmt"
commonUtils
"github.com/easysoft/zentaoatf/src/utils/common"
fileUtils
"github.com/easysoft/zentaoatf/src/utils/file"
i118Utils
"github.com/easysoft/zentaoatf/src/utils/i118"
logUtils
"github.com/easysoft/zentaoatf/src/utils/log"
"github.com/easysoft/zentaoatf/src/utils/vari"
"os"
"strings"
)
func
AddPath
()
{
ztfPath
:=
strings
.
TrimRight
(
vari
.
ZtfDir
,
string
(
os
.
PathSeparator
))
println
(
ztfPath
)
pathEnv
:=
os
.
Getenv
(
"PATH"
)
fmt
.
Println
(
pathEnv
)
if
strings
.
Index
(
pathEnv
,
ztfPath
)
==
-
1
{
if
commonUtils
.
IsWin
()
{
}
else
{
fileUtils
.
CopyFile
(
"./ztf"
,
"/usr/local/bin"
)
}
}
pathEnv
=
os
.
Getenv
(
"PATH"
)
fmt
.
Println
(
pathEnv
)
logUtils
.
PrintTo
(
i118Utils
.
I118Prt
.
Sprintf
(
"success_add_to_path"
))
}
src/model/config.go
浏览文件 @
30704558
...
...
@@ -8,13 +8,11 @@ type Config struct {
Account
string
Password
string
Bat
string
Javascript
string
Lua
string
Perl
string
Php
string
Python
string
Ruby
string
Shell
string
Tcl
string
}
src/utils/config/config.go
浏览文件 @
30704558
...
...
@@ -58,6 +58,10 @@ func PrintCurrConfig() {
val
:=
reflect
.
ValueOf
(
vari
.
Config
)
typeOfS
:=
val
.
Type
()
for
i
:=
0
;
i
<
reflect
.
ValueOf
(
vari
.
Config
)
.
NumField
();
i
++
{
if
!
commonUtils
.
IsWin
()
&&
i
>
4
{
break
}
val
:=
val
.
Field
(
i
)
name
:=
typeOfS
.
Field
(
i
)
.
Name
...
...
src/ztf.go
浏览文件 @
30704558
...
...
@@ -119,9 +119,6 @@ func main() {
case
"clean"
,
"-clean"
,
"-c"
:
action
.
Clean
()
//case "addpath", "-a":
// action.AddPath()
case
"help"
,
"-h"
:
logUtils
.
PrintUsage
()
...
...
xdoc/build.sh
0 → 100755
浏览文件 @
30704558
rm
-rf
ztf
mkdir
ztf
mkdir
ztf/log
cp
-r
conf ztf/
cp
-r
demo ztf/
go-bindata
-o
=
res/res.go
-pkg
=
res res/ res/doc res/json res/template
CGO_ENABLED
=
0
GOOS
=
windows
GOARCH
=
amd64 go build
-o
ztf/ztf.exe src/ztf.go
GO_ENABLED
=
0
GOOS
=
linux
GOARCH
=
amd64 go build
-o
ztf/ztf-linux src/ztf.go
CGO_ENABLED
=
0
GOOS
=
darwin
GOARCH
=
amd64 go build
-o
ztf/ztf-mac src/ztf.go
cd
ztf
zip
-r
ztf-win-2.0.RC.zip ztf.exe demo conf log
cp
-r
ztf-linux ztf
zip
-r
ztf-linux-2.0.RC.zip ztf demo conf log
cp
-r
ztf-mac ztf
zip
-r
ztf-mac-2.0.RC.zip ztf demo conf log
rm
ztf
cd
..
\ No newline at end of file
xdoc/setup.txt
浏览文件 @
30704558
rm -rf ztf
mkdir ztf
mkdir ztf/log
cp -r conf ztf/
cp -r demo ztf/
go-bindata -o=res/res.go -pkg=res res/ res/doc res/json res/template
CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -o ztf/ztf.exe src/ztf.go
GO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o ztf/ztf-linux src/ztf.go
CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -o ztf/ztf-mac src/ztf.go
cd ztf
zip -r ztf-win-2.0.RC.zip ztf.exe demo conf log
cp -r ztf-linux ztf
zip -r ztf-linux-2.0.RC.zip ztf demo conf log
cp -r ztf-mac ztf
zip -r ztf-mac-2.0.RC.zip ztf demo conf log
rm ztf
cd ..
error_log(json_encode($_POST, JSON_FORCE_OBJECT));
Python:
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple requests
Ruby:
sudo apt-get install libgmp3-dev
sudo gem install json
\ No newline at end of file
sudo gem install json
error_log(json_encode($_POST, JSON_FORCE_OBJECT));
\ No newline at end of file
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录