0
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-01 09:24:20 -04:00
denoland-deno/msg.proto
2018-05-15 04:50:45 -04:00

40 lines
600 B
Protocol Buffer

syntax = "proto3";
package main;
message Msg {
enum MsgKind {
START = 0;
READ_FILE_SYNC = 1;
DATA_RESPONSE = 2;
EXIT = 3;
COMPILE_OUTPUT = 4;
}
MsgKind kind = 10;
oneof payload {
StartMsg start = 90;
CompileOutputMsg compile_output = 100;
}
// READ_FILE_SYNC and MKDIRP
string path = 20;
// DATA_RESPONSE
bytes data = 30;
string error = 31;
// EXIT
int32 code = 40;
}
// START
message StartMsg {
string cwd = 1;
repeated string argv = 2;
}
// WRITE_COMPILE_OUTPUT
message CompileOutputMsg {
string source = 1;
string filename = 2;
}