feat: Support for other ways for declaring file-directories in a brick
- Lingua principale
- Dart
- Stelle
- 1.1k
- Fork
- 113
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Descrizione
## Description
With mustache templates, file names become too long to write and manage.
Git too throws when using file long names. (Example of error below)
```error: open("bricks/generate/__brick__/{{#has_tests}}test/widgets/{{#is_schematic_widget}}{{name.snakeCase()}}/{{#needs_theme_for_widget}}{{name.snakeCase()}}_theme_test.dart{{/needs_theme_for_widget}}{{/is_schematic_widget}}{{/has_tests}}"): Filename too long```
Although this issue can be resolved by `git config core.longpaths true`, writing with this template syntax becomes difficult for very large projects.
Is there any pattern or syntax that can help with this issue? Can we keep a file that describes file folder conditions?
What if we could keep a file `__brick__` that will decide to keep directories or files?
```
├───lib/some/file.dart
├───test/some/file_test.dart
└───__brick__
```
```__brick__
// This is for keeping `test/` directory if `has_tests` is true.
{{#has_tests}}test{{/has_tests}}
```
## Additional Context
### Example of file directory structure in `__brick__/`

Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Valutazione
Questa issue non è ancora stata valutata.