fix
This commit is contained in:
parent
39dd454be0
commit
46a7bcca87
@ -1,6 +1,6 @@
|
|||||||
syntax = "proto3";
|
syntax = "proto3";
|
||||||
|
|
||||||
package message;
|
//package message;
|
||||||
|
|
||||||
// 基础公共类型定义
|
// 基础公共类型定义
|
||||||
|
|
||||||
|
|||||||
19
proto/tun.proto
Normal file
19
proto/tun.proto
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
syntax = "proto3";
|
||||||
|
|
||||||
|
// 事件定义
|
||||||
|
|
||||||
|
message NEMessage {
|
||||||
|
// 网络出口ip改变映射变化, 空字符串表示关闭
|
||||||
|
message ExitNodeIpChanged {
|
||||||
|
string ip = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
oneof message {
|
||||||
|
ExitNodeIpChanged exit_node_ip_changed = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
message NEReply {
|
||||||
|
int32 code = 1;
|
||||||
|
string message = 2;
|
||||||
|
}
|
||||||
16
swift_pb.sh
Executable file
16
swift_pb.sh
Executable file
@ -0,0 +1,16 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
|
||||||
|
rm -rf tmp
|
||||||
|
mkdir tmp
|
||||||
|
cp proto/sdlan.proto tmp/sdlan_pb.proto
|
||||||
|
cp proto/tun.proto tmp/tun_pb.proto
|
||||||
|
|
||||||
|
cd tmp
|
||||||
|
|
||||||
|
protoc sdlan_pb.proto --swift_out=.
|
||||||
|
cp sdlan_pb.pb.swift SDLMessage.pb.swift
|
||||||
|
cp SDLMessage.pb.swift /usr/local/code/macos/punchnet/Tun/Punchnet/
|
||||||
|
|
||||||
|
protoc tun_pb.proto --swift_out=.
|
||||||
|
cp tun_pb.pb.swift TunMessage.pb.swift
|
||||||
|
cp TunMessage.pb.swift /usr/local/code/macos/punchnet/Tun/Punchnet/
|
||||||
Loading…
x
Reference in New Issue
Block a user