Skip to content

librarian: can't create "one-time-only-generated" files during configure #1922

@jskeet

Description

@jskeet

We've moved the generation of README.md and version.go (both internal and client-specific) files out of the "generate" container command, hoping to create them in the "configure" command (and update them as appropriate in the "release-init" command).

However, the configure command only gets to write to the generator-input directory (as well as writing the response to the .librarian directory). The plan for global files would allow it to write to other directories, but that's intended to be for cross-API files.

I wonder whether we should actually provide write access to the full repo, and then validate afterwards that all changed files are either in the declared "global" files list, or within one of the source roots. (The resulting directory structure would very likely be incomplete, but generate is always run straight afterwards.)

Additionally, if we do create README.md as a "generate once, then hand-maintain thereafter" file, that creates potential problems if we later want to change the template files. I know @meltsufin was thinking about this at some point, and may have thoughts.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions