Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
老鱼er
et
提交
c217daa9
E
et
项目概览
老鱼er
/
et
与 Fork 源项目一致
从无法访问的项目Fork
通知
10
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
E
et
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
c217daa9
编写于
10月 23, 2016
作者:
T
tanghai
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1.unity增加同步到Linux功能
2.服务器增加Start脚本
上级
f2db1768
变更
5
显示空白变更内容
内联
并排
Showing
5 changed file
with
32 addition
and
10 deletion
+32
-10
Server/Model/Component/AppManagerComponent.cs
Server/Model/Component/AppManagerComponent.cs
+8
-2
Server/Start.sh
Server/Start.sh
+5
-0
Tools/cwRsync/rsyncd.conf
Tools/cwRsync/rsyncd.conf
+6
-3
Unity/Assets/Editor/RsyncEditor/RsyncEditor.cs
Unity/Assets/Editor/RsyncEditor/RsyncEditor.cs
+11
-3
Unity/Unity.CSharp.Editor.csproj
Unity/Unity.CSharp.Editor.csproj
+2
-2
未找到文件。
Server/Model/Component/AppManagerComponent.cs
浏览文件 @
c217daa9
...
...
@@ -39,14 +39,20 @@ namespace Model
#if __MonoCS__
const
string
exe
=
@"mono"
;
string
arguments
=
$"App.exe --id=
{
startConfig
.
Options
.
Id
}
--appType=
{
startConfig
.
Options
.
AppType
}
"
;
const
string
workDir
=
@"../Server/Bin/Debug"
;
#else
const
string
exe
=
@"App.exe"
;
string
arguments
=
$"--id=
{
startConfig
.
Options
.
Id
}
--appType=
{
startConfig
.
Options
.
AppType
}
"
;
const
string
workDir
=
@"..\Server\Bin\Debug"
;
#endif
ProcessStartInfo
info
=
new
ProcessStartInfo
(
exe
,
arguments
)
Log
.
Debug
(
$"
{
startConfig
.
Options
.
Id
}
{
MongoHelper
.
ToJson
(
startConfig
)}
"
);
ProcessStartInfo
info
=
new
ProcessStartInfo
{
FileName
=
exe
,
Arguments
=
arguments
,
CreateNoWindow
=
true
,
UseShellExecute
=
true
,
WorkingDirectory
=
@"..\Server\Bin\Debug"
WorkingDirectory
=
workDir
};
Process
process
=
Process
.
Start
(
info
);
...
...
Server/Start.sh
0 → 100644
浏览文件 @
c217daa9
#!/bin/bash
cd
Bin/Debug/
pkill App.exe
mono App.exe
--id
=
1
--appType
=
Manager
\ No newline at end of file
Tools/cwRsync/rsyncd.conf
浏览文件 @
c217daa9
...
...
@@ -3,9 +3,12 @@ gid = root
#strict modes = no
use
chroot
=
no
max
connections
=
100
[
Source
]
path
= /
home
/
tanghai
/
Source
/
read
only
=
no
write
only
=
no
log
file
=/
var
/
log
/
rsyncd
.
log
# Remote sync configuration module
[
Tanghai
]
path
= /
home
/
tanghai
/
auth
users
=
tanghai
secrets
file
= /
etc
/
rsyncd
.
secrets
list
=
yes
\ No newline at end of file
Unity/Assets/Editor/RsyncEditor/RsyncEditor.cs
浏览文件 @
c217daa9
using
System
;
using
System.Diagnostics
;
using
Base
;
using
UnityEditor
;
namespace
MyEditor
{
public
class
RsyncEditor
:
EditorWindow
{
[
MenuItem
(
"Tools/
Rsync
"
)]
[
MenuItem
(
"Tools/
同步到Linux
"
)]
private
static
void
ShowUnDisposeObjects
()
{
Process
.
Start
(
"../Tools/cwRsync/rsync.exe"
,
""
);
ProcessStartInfo
startInfo
=
new
ProcessStartInfo
();
startInfo
.
FileName
=
@"Tools\cwRsync\rsync.exe"
;
startInfo
.
Arguments
=
"-vzrtopg --password-file=./Tools/cwRsync/rsync.secrets --exclude-from=./Tools/cwRsync/exclude.txt --delete ./ tanghai@192.168.1.134::Tanghai/Source/Egametang --chmod=ugo=rwX"
;
startInfo
.
UseShellExecute
=
true
;
startInfo
.
WorkingDirectory
=
@"..\"
;
Process
p
=
Process
.
Start
(
startInfo
);
p
.
WaitForExit
();
Log
.
Info
(
"同步完成!"
);
}
}
}
Unity/Unity.CSharp.Editor.csproj
浏览文件 @
c217daa9
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project
ToolsVersion=
"4.0"
DefaultTargets=
"Build"
xmlns=
"http://schemas.microsoft.com/developer/msbuild/2003"
>
<PropertyGroup>
<Configuration
Condition=
" '$(Configuration)' == '' "
>
Debug
</Configuration>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录