-
Notifications
You must be signed in to change notification settings - Fork 120
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrate to full use of tools/resourcedocsgen (#4663)
* Migrate registrygen's metadata command to tools/resourcedocsgen * Ignore the build resourcedocsgen binary * Special-case Pulumi for top-level config files not found * Update Go module name and update references * Use resourcedocsgen for generating package metadata Update README reference * Transport pkgversion check to resourcedocsgen * Replace pkgversion check * Update tools/resourcedocsgen/cmd/metadata.go Co-authored-by: Ian Wahbe <[email protected]> * package is a reserved word * Fix command verbiage * Do not commit binary file --------- Co-authored-by: Ian Wahbe <[email protected]>
- Loading branch information
1 parent
de84037
commit 86756fd
Showing
15 changed files
with
613 additions
and
255 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -55,28 +55,25 @@ jobs: | |
- name: Sleep to prevent hitting secondary rate limits | ||
if: steps.skip-run.outputs.skip != 1 | ||
run: sleep 1 | ||
- name: Install Registrygen CLI | ||
if: steps.skip-run.outputs.skip != 1 | ||
uses: jaxxstorm/[email protected] | ||
with: | ||
repo: pulumi/registrygen | ||
- name: Check for a new version | ||
if: steps.skip-run.outputs.skip != 1 | ||
id: version | ||
run: | | ||
echo 'PROVIDER_VERSION<<EOF' >> $GITHUB_ENV | ||
registrygen pkgversion --repoSlug ${{ matrix.repoSlug }} \ | ||
cd tools/resourcedocsgen && \ | ||
go run github.com/pulumi/registry/tools/resourcedocsgen pkgversion --repoSlug ${{ matrix.repoSlug }} \ | ||
>> $GITHUB_ENV | ||
echo 'EOF' >> $GITHUB_ENV | ||
# This will only be populated if the registry version does not match the latest provider version. | ||
- name: Display new version | ||
if: env.PROVIDER_VERSION | ||
run: echo ${{ env.PROVIDER_VERSION}} | ||
# We only need to run the following steps if registrygen found a newer version of the community provider. | ||
# We only need to run the following steps if resourcedocsgen found a newer version of the community provider. | ||
- name: Generate Package Metadata | ||
if: env.PROVIDER_VERSION | ||
run: | | ||
registrygen metadata --repoSlug ${{ matrix.repoSlug }} --schemaFile ${{ matrix.schemaFile }} \ | ||
cd tools/resourcedocsgen && go run github.com/pulumi/registry/tools/resourcedocsgen \ | ||
metadata --repoSlug ${{ matrix.repoSlug }} --schemaFile ${{ matrix.schemaFile }} \ | ||
--version ${{ env.PROVIDER_VERSION }} | ||
- name: Create registry PR | ||
if: env.PROVIDER_VERSION | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,13 +22,10 @@ jobs: | |
- run: echo "Building ${{ env.PROVIDER_NAME }} docs @ ${{ env.PROVIDER_VERSION }}" | ||
- name: checkout registry repo | ||
uses: actions/checkout@v2 | ||
- name: Install Registrygen CLI | ||
uses: jaxxstorm/[email protected] | ||
with: | ||
repo: pulumi/registrygen | ||
- name: Generate Package Metadata | ||
run: | | ||
registrygen metadata --providerName=${{ env.PROVIDER_SHORT_NAME }} --repoSlug pulumi/pulumi-${{ env.PROVIDER_SHORT_NAME }} --schemaFile="${{ env.PROVIDER_SCHEMA_PATH }}" --version="${{ env.PROVIDER_VERSION }}" --publisher Pulumi | ||
cd tools/resourcedocsgen && go run github.com/pulumi/registry/tools/resourcedocsgen \ | ||
metadata --providerName=${{ env.PROVIDER_SHORT_NAME }} --repoSlug pulumi/pulumi-${{ env.PROVIDER_SHORT_NAME }} --schemaFile="${{ env.PROVIDER_SCHEMA_PATH }}" --version="${{ env.PROVIDER_VERSION }}" --publisher Pulumi | ||
- name: git status | ||
run: git status && git diff | ||
- name: Create registry PR | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,3 +10,4 @@ public | |
.vscode | ||
cypress/videos | ||
cypress/screenshots | ||
tools/resourcedocsgen/resourcedocsgen |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.