workout-note-parser 0.1.1

Parse workout notes into JSON format.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
workout = { SOI ~ (exercise | NEWLINE)+ ~ EOI }
exercise = { name ~ (NEWLINE ~ set)+ }
name = { (!NEWLINE ~ ANY)* }
set = { weight ~ "x" ~ reps ~ ("+" ~ set)* ~ comment? }
comment = { (!NEWLINE ~ ANY)+ }
weight = {
    ASCII_DIGIT+ ~ "." ~ ASCII_DIGIT+
  | ASCII_DIGIT+
}

reps = { ASCII_DIGIT+ }

WHITESPACE = _{ " " | "\t" }