Make `FS` smart about the year in generated license headers
- Dominant language
- Go
- Stars
- 10
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
As it is currently written, `codejen.FS` treats all bytes as undifferentiated. This is fine, for now. But when the year rolls over, [lines like this](https://github.com/grafana/grafana/blob/main/public/app/plugins/panel/barchart/models.cue#L1), will be updated.
This isn't usually the way that license headers work - typically the year is left alone, once the file is created.
While i do want to avoid putting too much smarts into the `codejen.FS`, i'd be comfortable with a hack that sniffs specifically for a regex pattern like that in a file that it's writing to or verifying, and dynamically changing the bytes in its buffer to be the year that's in the file already on disk.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.