From d71913f1dbad3914dbfa4d287dc2d1b55d091d64 Mon Sep 17 00:00:00 2001 From: Goutte Date: Sat, 16 Mar 2019 22:32:32 +0100 Subject: [PATCH] Add other suggestions of file paths implementation So far, v3 is my favorite. --- SPECIFICATIONS.md | 50 ++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 43 insertions(+), 7 deletions(-) diff --git a/SPECIFICATIONS.md b/SPECIFICATIONS.md index 0a7ff1eae..c6f1bad23 100644 --- a/SPECIFICATIONS.md +++ b/SPECIFICATIONS.md @@ -6,13 +6,7 @@ ## Files Paths -``` -[/]/chapter-.. -or -[/]/--<type>.<language>.<format> -or -??? -``` +Let: - `topic`: lowercase alphanumeric topic name (in english, sorry) - `NN`: level of the course, an integer with always two digits @@ -21,11 +15,53 @@ or - `textbook` - `cheatsheet` (?) - `annex` + - `exercises` - `language`: 2 letter lowercase language code - `format`: `md` for markdown +Let's review our options, now. + +## Files Paths v1 + +``` +<topic>[/<topic>]/chapter<NN>-<type>.<language>.<format> +or +<topic>[/<topic>]/<NN>-<title>-<type>.<language>.<format> +or +??? +``` + + +## Files Paths v2 + +``` +<N>.<topic>[/<M>.<topic>]/<K>.<slug>/<type>.<language>.<format> +``` + +Each chapter gets its own directory, which will be simpler for assets organization. + +`01.optics/03.the-nature-of-light/textbook.fr.md` + + + +## Files Paths v3 + +`en/01.optics/03.the-nature-of-light/textbook.md` + +`fr/01.optique/03.la-nature-de-la-lumiere/cahier.md` + +Pros: + - Everything + +Cons: + - Will rely on Ids, so changing them afterwards is fastidious + -> Can be mitigated by initially generating an empty topic dir structure + +----- + + ## Courses Model Each Course MUST have: