Skip to content

Commit

Permalink
fix owlbot templates
Browse files Browse the repository at this point in the history
  • Loading branch information
diegomarquezp committed Feb 20, 2024
1 parent 2fe07c4 commit 3368abd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
3 changes: 3 additions & 0 deletions library_generation/owlbot/bin/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,11 @@ python3 "${scripts_root}/owlbot/src/apply_repo_templates.py" "${configuration_ya
echo "Retrieving files from owl-bot-staging directory..."
if [ -f "owlbot.py" ]
then
# we use an empty synthtool folder to prevent cached templates from being used
export SYNTHTOOL_TEMPLATES=$(mktemp -d)
# defaults to run owlbot.py
python3 owlbot.py
export SYNTHTOOL_TEMPLATES=""
fi
echo "...done"

Expand Down
8 changes: 4 additions & 4 deletions library_generation/owlbot/templates/java_library/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% set group_id = metadata['repo']['distribution_name'].split(':')|first -%}
{% set artifact_id = metadata['repo']['distribution_name'].split(':')|last -%}
{% set repo_short = metadata['repo']['repo'].split('/')|last -%}
{% set repo_short = metadata['repo']['repo_short'] if metadata['repo']['repo_short'] else metadata['repo']['repo'].split('/')|last -%}

# Google {{ metadata['repo']['name_pretty'] }} Client for Java

Expand Down Expand Up @@ -273,9 +273,9 @@ Java is a registered trademark of Oracle and/or its affiliates.
[create-project]: https://cloud.google.com/resource-manager/docs/creating-managing-projects
[cloud-cli]: https://cloud.google.com/cli
[troubleshooting]: https://github.com/googleapis/google-cloud-java/blob/main/TROUBLESHOOTING.md
[contributing]: https://github.com/{{metadata['repo']['repo']}}/blob/main/CONTRIBUTING.md
[code-of-conduct]: https://github.com/{{metadata['repo']['repo']}}/blob/main/CODE_OF_CONDUCT.md#contributor-code-of-conduct
[license]: https://github.com/{{metadata['repo']['repo']}}/blob/main/LICENSE
[contributing]: https://github.com/{{repo_short]}}/blob/main/CONTRIBUTING.md
[code-of-conduct]: https://github.com/{{repo_short}}/blob/main/CODE_OF_CONDUCT.md#contributor-code-of-conduct
[license]: https://github.com/{{repo_short}}/blob/main/LICENSE
{% if metadata['repo']['requires_billing'] %}[enable-billing]: https://cloud.google.com/apis/docs/getting-started#enabling_billing{% endif %}
{% if metadata['repo']['api_id'] %}[enable-api]: https://console.cloud.google.com/flows/enableapi?apiid={{ metadata['repo']['api_id'] }}{% endif %}
[libraries-bom]: https://github.com/GoogleCloudPlatform/cloud-opensource-java/wiki/The-Google-Cloud-Platform-Libraries-BOM
Expand Down

0 comments on commit 3368abd

Please sign in to comment.