Go to file
2020-11-04 22:32:26 +01:00
example "initial" 2020-11-04 22:27:06 +01:00
test "initial" 2020-11-04 22:27:06 +01:00
.gitignore ignore .gitdist files 2020-11-04 22:32:26 +01:00
generator.go "initial" 2020-11-04 22:27:06 +01:00
go.mod "initial" 2020-11-04 22:27:06 +01:00
lexer.go "initial" 2020-11-04 22:27:06 +01:00
License.md "initial" 2020-11-04 22:27:06 +01:00
parser.go "initial" 2020-11-04 22:27:06 +01:00
plateSearch.go "initial" 2020-11-04 22:27:06 +01:00
Readme.md typos and headings in readme 2020-11-04 22:29:02 +01:00
TDL_test.go "initial" 2020-11-04 22:27:06 +01:00
TDL.go "initial" 2020-11-04 22:27:06 +01:00
types.go "initial" 2020-11-04 22:27:06 +01:00

TDL

TDL is a language for weightlifting schedules and a corresponding generator. From a file with descriptions of sets and percentages the program computes concrete training days and plates needed.

Usage

$ TDL yourSchedule.tdl

You find the output in yourSchedule-TIMESTAMP.txt

See the examples folder for inspiration to write your schedule file.

Beer Note

You can buy me a beer here.

Grammar

For completeness' sake, the grammar in EBNF looks like this. You don't have to read this to use the program!

TDL = Lifts [Plates] [SetTemplates] TrainingDays EOI .

Lifts = "Lifts:" Lift {"," Lift} .

Lift = LiftIdent "Max:" Weight "Increment:" Weight [ "%" ] [ "Bar:" Weight ] .

Plates = "Plates:" Plate { "," Plate } .

Plate =  Weight 'x' Amount .

SetTemplates = "SetTemplates:" "-" SetTemplate { "-" SetTemplate } .

SetTemplate = SetTemplateIdent SetTemplateItem { ',' SetTemplateItem } .

SetTemplateItem = SetTemplateIdent | Set [ 'x' Amount ] .

Set = Amount "reps" '@' Percentage '%' [ '+' Weight ] [ 'x' Amount ] [ Notice ] .

TrainingDays = "TrainingDays:" "-" TrainingDay { "-" TrainingDay } .

TrainingDay = TrainingDayItem { TrainingDayItem } .

TrainingDayItem = string | LiftSchedule.

LiftSchedule = LiftIdent ':' SetTemplateItem { ',' SetTemplateItem } [ "increase" [ Weight [ "%" ] ] ] .

Amount = integer .

Percentage = integer|float .

Weight = integer|float .

LiftIdent = ident .

SetTemplateIdent = ident .

Notice = '(' ANY ')' .

Comments can be enclosed in square brackets and are ignored.