Commit d478ee1
committed
feat: add template file metadata types in file.rs module
Add comprehensive template file metadata representation with:
- File struct for storing template metadata (path, format, engine type)
- Engine enum (Static, Tera) for template processing type detection
- Format enum (Yml, Toml, Tf, Tera) for output format identification
- Extension enum for supported file extensions
- Robust error handling with thiserror for file parsing errors
- Extensive test coverage (46 test cases) for edge cases and validation
- Support for both static files and Tera templates with inner format detection
This provides a standardized way to represent and validate template files
without handling actual rendering or I/O operations.1 parent c72ca6f commit d478ee1
4 files changed
+889
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
| 35 | + | |
35 | 36 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
41 | 42 | | |
42 | 43 | | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
0 commit comments