generated from KOLANICH/python_project_boilerplate.py
-
Notifications
You must be signed in to change notification settings - Fork 0
/
smsd.yug
92 lines (89 loc) · 1.5 KB
/
smsd.yug
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
meta:
id: smsd
title: SMSD command
license: Unlicense
class: regular
doc: A grammar for SMSD text serial commands
tests:
- model: lines
files:
- "tests.txt"
chars:
- id: digit
wellknown: digits
- id: plus
lit: +
- id: minus
lit: '-'
- id: sign
alt:
- ref: plus
- ref: minus
keywords:
- id: optional_arg_verb
alt:
- lit: LD
- lit: MV
- lit: ST
- lit: PS
- id: no_arg_verb
alt:
- lit: BG
- lit: EN
- lit: DL
- lit: DR
- lit: RS
- lit: EN
- lit: DS
- lit: ON
- lit: OF
- lit: SF
- lit: WL
- lit: WH
- lit: CF
- lit: LL
- lit: ED
- id: unsigned_arg_verb
alt:
- lit: SD
- lit: SS
- lit: SP
- lit: JP
- id: signed_arg_verb
lit: AL
tokens:
- id: unsigned_number
ref: digit
min: 1
- id: signed_number
seq:
- opt:
ref: sign
- ref: unsigned_number
prods:
- id: command
alt:
- ref: opt_arg_command
- ref: unsigned_command
- ref: signed_command
- id: signed_command
seq:
- ref: signed_arg_verb
cap: verb
- ref: signed_number
cap: arg
- id: unsigned_command
seq:
- ref: unsigned_arg_verb
cap: verb
- ref: unsigned_number
cap: arg
- id: opt_arg
opt:
ref: unsigned_number
- id: opt_arg_command
seq:
- ref: optional_arg_verb
cap: verb
- ref: opt_arg
cap: arg