-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbang.proto
More file actions
26 lines (22 loc) · 749 Bytes
/
Copy pathbang.proto
File metadata and controls
26 lines (22 loc) · 749 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
syntax = "proto3";
package bang;
message Bang {
// Name of the Bang, which is used as its ID.
string name = 1;
// Format of the Bang, where '{{{s}}}' will be substituted with the escaped
// query string.
string format = 2;
// Description is a summary of the Bang.
string description = 3;
// EscapeMethod is the type of escaping to be used when escaping non-URL
// safe characters, like spaces and quotes.
enum EscapeMethod {
// Escapes the input with url.QueryEscape: "cat pictures" => "cat+pictures"
QUERY_ESCAPE = 0;
// Does no escaping: "cat pictures" => "cat pictures"
PASS_THROUGH = 1;
// Escapes the input with url.PathEscape: "cat pictures" => "cat%20pictures"
PATH_ESCAPE = 2;
}
EscapeMethod escape_method = 4;
}