Skip to content

Commit 2070213

Browse files
chore: clean up repository onboarding documentation (#2788)
Cleaned up repository onboarding documentation: 1) Post processing files should remove mention of owlbot (in file name), to indicate that these files are being used by Librarian and not legacy owlbot system. 2) Added clarity around ticket opening for a new repository. 3) Fixed invalid links. 4) Separated owlbot/release please specific instructions into a separate section. --------- Signed-off-by: ldetmer <[email protected]> Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
1 parent 83ecc8b commit 2070213

File tree

1 file changed

+10
-6
lines changed

1 file changed

+10
-6
lines changed

doc/repository-library-onboarding.md

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
This guide should be followed when onboarding new repositories/libraries.
44

55
## Repository Setup:
6-
1) [Create ticket](http://go/onboard-repository-to-librarian) to onboard repository to Librarian automation. At a minimum, you should onboard to Tag and Release automation.
7-
2) Add `.librarian` directory to your repository with appropriate configuration files. See details [here](https://github.com/googleapis/librarian/blob/main/doc/language-onboarding.md#configuration-files)
6+
1) [Create a ticket](http://go/onboard-repository-to-librarian) to onboard a repository to Librarian automation (automation is per repository not library). At a minimum, you should onboard to [tag-and-release](https://pkg.go.dev/github.com/googleapis/librarian/cmd/librarian#hdr-release_tag_and_release) automation.
7+
2) Add `.librarian` directory to your repository with appropriate configuration files. See details [here](https://github.com/googleapis/librarian/blob/main/doc/language-onboarding.md#configure-repository-to-work-with-librarian-cli)
88
3) You should only start with 1 library to validate the flow (follow instructions below)
99
4) If your repository contains multiple libraries, start ramping up slowly until all libraries are in your `state.yaml` file and have migrated to librarian.
1010
5) To complete onboarding you should run the librarian test-container generate command to validate that all libraries are getting generated correctly. Note this command is WIP, [documentation will be added](https://github.com/googleapis/librarian/issues/2621) once available.
@@ -13,14 +13,18 @@ and set the default commit message to **Pull request title and description**.
1313
![Pull request settings](assets/setting-pull-requests.webp)
1414

1515
## Library Setup:
16+
17+
### If you currently are using owlbot/release-please for generation and release:
1618
1) Ensure all OwlBot PRs for that library have been merged and then release the library using a release-please PR
1719
2) Remove the library from your OwlBot config
1820
- If you have an .Owlbot.yaml config file with multiple libraries, remove the library from .Owlbot.yaml file.
1921
- If your .Owlbot.yaml config file contains only the single library, remove the .Owlbot.yaml file itself.
2022
3) Remove the library from your release-please config
2123
- For a monolithic repo remove the path entry for the library in your release-please-config.json and .release-please-manifest.json files
2224
- For a single library repository, remove all the release-please config (.github/release-please.yml, release-please-config.json if it exists, .release-please-manifest.json if it exists)
23-
4) There is no requirement to stop using library-specific OwlBot post-processing files as part of this migration. However, while migrating, please open an issue in your generator repository for any improvements that could reduce your library's post-processing logic.
24-
5) Add your library to your [libraries object](https://github.com/googleapis/librarian/blob/main/doc/state-schema.md#libraries-object) in your [state.yaml](https://github.com/googleapis/librarian/blob/main/doc/state-schema.md#stateyaml-schema) file
25-
6) Run [librarian generate command](https://github.com/googleapis/librarian/blob/main/doc/cli-commands.md#generate-command). The output should be 0 diff, check with your language lead/generator owner if this is not the case.
26-
7) Be aware of the `generate_blocked` and `release_blocked` fields in the [config.yaml file](https://github.com/googleapis/librarian/blob/main/doc/config-schema.md#libraries-object). If these are set to `true` and automation is enabled for the repository ([check here](https://github.com/googleapis/librarian/blob/main/internal/automation/prod/repositories.yaml)), then generate and release PRs will be created and merged automatically. If these actions are blocked, or your repository is not set up for automation, you will have to perform these actions manually. See this [guide](https://github.com/googleapis/librarian/blob/main/doc/library-maintainer-guide.md) for details
25+
4) There is no requirement to stop using library-specific post-processing files as part of this migration. However, any post processing should be included in a file named "librarian.<ext>", where <ext> corresponds to the script's file extension (e.g., "sh", "py"). While migrating, please also consider opening an issue in your generator repository for any improvements that could reduce your library's post-processing logic.
26+
27+
### General Library Setup Steps
28+
1) Add your library to your [libraries object](https://github.com/googleapis/librarian/blob/main/doc/state-schema.md#libraries-object) in your [state.yaml](https://github.com/googleapis/librarian/blob/main/doc/state-schema.md#stateyaml-schema) file.
29+
2) Run [librarian generate command](https://pkg.go.dev/github.com/googleapis/librarian/cmd/librarian#hdr-generate). The output should be 0 diff, check with your language lead/generator owner if this is not the case.
30+
3) Be aware of the `generate_blocked` and `release_blocked` fields in the [config.yaml file](https://github.com/googleapis/librarian/blob/main/doc/config-schema.md#libraries-object). If these are not set and automation is enabled for the repository ([check here](https://github.com/googleapis/librarian/blob/main/internal/automation/prod/repositories.yaml)), then generate and release PRs will be created and merged automatically. If these actions are blocked, or your repository is not set up for automation, you will have to perform these actions manually. See this [guide](https://github.com/googleapis/librarian/blob/main/doc/library-maintainer-guide.md) for details.

0 commit comments

Comments
 (0)