Mustache

Timeline
Login
Bounty program for improvements to Tcl and certain Tcl packages.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

38 check-ins

2021-08-13
21:18
feat: New generic method `is` for `mustache::frame` instances. feat: New methods for `mustache::frame` scalar/mapping instances. feat: New `string!` type for package `mustache::frame`. Use `string!` over `string` to avoid magic mustache specifications shenanigans (likely coming out of ruby). Note, `string!` is now standard for conversion from and to YAML string elements. New methods: Type check, change scalar value in place, add/remove/move key assignments in mappings. Leaf check-in: 859f44a892 user: aku tags: trunk
2021-03-15
20:19
fix: Split README into fossil and github variants Use general structure from Ankh. check-in: 2f1f2ad36c user: aku tags: trunk
20:07
fix: Reworked the documentation for getting the sources, for clarity. fix: Broken schema in a number of links to core. Regenerated. check-in: 283fecf8ef user: aku tags: trunk
2021-03-06
19:04
Bumped project to version 1.1. * Extended the [package mustache::frame] package to support the TclYAML version 0.5 tags for `bool`, `float`, `int`, `null`, and `string`. The pre-existing tag `scalar` is now an alias for `string`. This extension of the type system makes it easier to use mustache's data frames as an in-memory representation for structured typed data. No automatic loss of type data inside of Tcl scripts now. * Extended the data frames provided by package `mustache::frame` with methods for walking a frame tree in general, and simplifying the conversion back into external serialization formats. * Extended the sequence and mapping data frames provided by package `mustache::frame` with methods (`for`) for iteration over the content, without a context. * Added packages for the conversion of a data frame (tree) into various serializations: - `mustache::frame::as::events` - Serialization into a list of events describing the incremental build of the tree. - `mustache::frame::as::json` - Serialization into whitespace-free JSON. - `mustache::frame::as::tagged` - Serialization into the kind of tagged structure accepted by TclYAML's `writeTags` command. Updated documentation. Regenerated the dependent files. check-in: 5a38048d14 user: aku tags: trunk, v1.1
2021-02-08
22:48
Fixed the missing trailing spaces in .md files. They are intentional, indicating hard line breaks. Updated the external tooling to now ignore all Markdown files when doing cleanup of trailing whitespace. check-in: 7ce6c31f7b user: aku tags: trunk
22:38
Regenerated the documentation. __Note__: This used the latest Tcllib (1.20+internal), to get the fixes to a number of issues with markdown output. check-in: 9df23435b6 user: aku tags: trunk
22:03
Added github-specific files to the toplevel directory. Centralized the url definitions. Added markdown to the embedded documentation, by using the latest Kettle. Regenerated the dependent files. check-in: 1a1c506384 user: aku tags: trunk
2019-07-24
03:44
Integrated app doc and general doc work. check-in: dd81cba635 user: aku tags: trunk
03:43
More documentation tweaks. Regenerated embedded files. Closed-Leaf check-in: 2b516fd8cd user: aku tags: app-doc
2019-07-23
23:18
mustache application - Added documentation General tweaking of most documentation pages. - Larger welcome with more explanation. - Separation of main body from welcome via standard section. - Added package-specific keywords. - Miscellaneous. check-in: 287f47e3bc user: andreask tags: app-doc
17:19
mustache application - Added testsuite check-in: 96d0da0bb1 user: andreask tags: trunk
06:01
Added mustache application, plus examples. check-in: 1b9625262b user: aku tags: trunk
2019-07-22
21:57
Regenerated embedded docs. check-in: f85528deb0 user: aku tags: trunk
21:53
Added forgotten documentation for `mustache::frame::fromTags`. check-in: 05618d307e user: andreask tags: trunk
21:36
Bump to version 1 check-in: bd69d6dd80 user: andreask tags: trunk
21:28
Integrated dev work into main line. check-in: 36e13d5cf8 user: andreask tags: trunk
21:23
mustache::render - Added unit tests for partials. Closed-Leaf check-in: 02b5d79057 user: andreask tags: run-up
21:11
mustache::parse - Tweaks to the narrative tracing. - Support for partials. mustache::render - Support for partials. Brought back the supplemental tests. Brought back the test for partials. All tests pass. TODO: Add render unit tests for partials. check-in: 5d7da4d9fd user: andreask tags: run-up
06:11
Added package documentation. - Standard project data (intro, how to get sources, how to build/install, dev internals). - Manpages (command references) check-in: 3dd2eae403 user: aku tags: run-up
01:58
mustache::parse - Tests activated, and fixed. check-in: c253147411 user: aku tags: run-up
01:39
mustache::context, mustache::parse - Converted debug print commands into proper narrative tracing. check-in: 66778f039e user: aku tags: run-up
01:21
mustache::context, mustache::render - Added new tests for dotted fields. check-in: 90390a5ce6 user: aku tags: run-up
2019-07-20
00:00
Reworked handling of dotted fields. Cross-cut through parser, renderer, and context. - Removed parser transformation and .dot command variants. - Removed render support for .dot command variants. Removed tests dealing with .dot commands. - Removed context support for .dot command variants. Removed tests dealing with .dot commands. - Reworked context `has?` and `focus` methods to handle dotted fields and `.` alone. Method `has?` and its new helper `__find` are doing the actual resolution. Test suite passes. Notably the end-2-end suite from ruby mustache. Todo I: The render and context testsuites need new cases for the handling of dotted fields now. Todo II: Convert the debug output from parser and context into proper narrative tracing. check-in: 06f32b53bd user: andreask tags: run-up
2019-07-19
23:08
Continued work on the end2end tests (template + input -> result). - Fixed all remaining issues with handling of standalone tags. - Fixed misrender when using `.` as field reference in section. Only one test is not passing. It shows that the idea of handling dotted names by coding the resolution into the template AST is not really working out. Look at an inverted section with field `a.b`. - If `a` in `a.b` does not exist we still have to walk down to the innermost element to render it. This implies use of `isection` for `a`. - OTOH if `a` exists we are also expected to walk down again, to check the details of `b` about rendering vs not. Implies use of `section` for `a`. - Could be solved by switching to a new `resolve` command which performs one step of the resolution and then walks down. Would have to leave state information either in the render (upvar), or in the context object, for deeper resolvers and `(i)section` to pick up. At this point it should actually be easier to push the entire resolution into the `context` object. - That keeps the AST simple and not as deep. - No state to keep across command boundaries, it will be all local. - We can drop all the `.dot` variants for `var*` and `*section` commands. #Tests not passing: 1 check-in: 1eaeff700b user: andreask tags: run-up
17:10
mustache::frame - Treating doubles as numbers fixes the precision issues with the decimal interpolation testcases. Solution found in and snarfed from mustache.tcl. Thank you very much. check-in: ddc68ff9ca user: andreask tags: run-up
08:11
mustache - Added main package holding convenience commands to the functionality. - Activated main tests, using the yaml-based test cases. - Started fixing issues with tokenizer and structure. - Better standalone handling, although not fully there yet. - Bugs in dot decomposition for (i)section. - Parser/render interface. Leaf nodes have position information. Not yet solved: - Decimal interpolation, handling of precision. - Iteration, inverted, ... Number of tests currently not passing: 15. check-in: 0bcb99fd43 user: aku tags: run-up
05:12
mustache::render - Implemented section.dot, isection.dot, refactored shared code. - Continued work on testsuite. Complete except for partials. check-in: 7df1e527db user: aku tags: run-up
00:41
Added tests for sections. check-in: ae9bcc5f52 user: andreask tags: run-up
2019-07-18
23:28
General re-shuffling of input and result files for tests. The original yaml-based test cases are now under `tests/inputs/spec` and everything else will be in sibling directories of it. Similarly the local results (parse structures) associated with the yaml-based tests are now under `tests/results/spec`, and everything else is in sibling directories of it. The `z_` prefix for the local results is now gone as part of that. Started testsuite for the rendering backend. Untested: partials and all forms of sections. check-in: 45032c8f57 user: andreask tags: run-up
19:47
mustache::frame - Added tests for `fromTags`. Resolves TODO in the testsuite. check-in: 7813b3c8b3 user: andreask tags: run-up
19:40
mustache::context - Resolved the TODO's in the testsuite. Extended API with test support methods. check-in: eb6b18fdee user: andreask tags: run-up
19:27
Fix copy-pasta issue in whitespace cleaner tool, and applied it, i.e. cleaned accumulated whitespace. check-in: a65a40b73d user: andreask tags: run-up
17:52
Added some dev helper scripts check-in: 2121401fc8 user: aku tags: run-up
00:18
- Added tests for mustache::context - Extended context with dot variants of `focus` and `has?`. - Fixed issues in context, frame, and frame tests. - Added destructors to frame, context. Clarified object ownership. check-in: d169df8aeb user: andreask tags: run-up
2019-07-16
23:47
- Moved test utility commands into separate file. - Switched to TclYAML. Wanted its type-tagged results, for better conversion of input data into frames. - Updated existing tests to new yaml structures, more utility commands for decoding and processing. - Moved the code exploding the test suite into a dir/file hierarchy (and running the baseline ruby mustache), into a separate testsuite. - Implemented frame objects, conversion of tagged structures to frame hierarchy. Tests added. - Disabled (for now) all but the frame tests. check-in: 890065f3a7 user: andreask tags: run-up
18:20
Ignore build and test artifacts. check-in: cc4b6e9009 user: aku tags: run-up
18:17
Starting my own mustache processor in Tcl. Aware of https://github.com/ianka/mustache.tcl it has (IMHO) some shortcomings (*) I hope to address. Now: - Basic parser, not fully complete - Does not handle partials yet. - Does not handle standalone properly yet. - Most of a testsuite based on the original spec and yaml files found at https://github.com/mustache/spec - Start on context object and renderer. Todo: - Frame object and glue for testsuite (translation of the yaml context information into a frame). - May (have to) switch to TclYAML for better type information. ~~~ (*) Interpreter, no separation of compiler/render, reparses the template for nested sections over and over. check-in: 32af418f20 user: aku tags: run-up
2019-07-12
02:05
initial empty check-in check-in: 1e9380c68b user: aku tags: trunk