-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Implement Java Executor (#224)
PR: #224
- Loading branch information
Showing
8 changed files
with
129 additions
and
26 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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
name: Download API Specs | ||
on: | ||
workflow_call: | ||
inputs: | ||
url: | ||
description: 'URL to download API specs from' | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
download_specs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- id: download_specs | ||
run: | | ||
curl -L ${{ inputs.url }} -o raw-specs.yaml | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
name: raw-specs | ||
path: raw-specs.yaml |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Generate and Publish Sources | ||
on: | ||
workflow_call: | ||
inputs: | ||
name: | ||
description: 'SDK Name' | ||
required: true | ||
type: string | ||
version: | ||
description: 'SDK Version' | ||
required: true | ||
type: string | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: sdk | ||
path: generator/sdk | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: specs | ||
path: generator/sdk | ||
- name: Publish Code | ||
working-directory: generator/sdk | ||
run: | | ||
git config --global user.email "[email protected]" | ||
git config --global user.name "Expedia Group Open Source" | ||
rm -rf ../../release/"${{github.event.inputs.name}}" | ||
mkdir -p ../../release/"${{github.event.inputs.name}}" | ||
cp -r ./src ../../release/"${{github.event.inputs.name}}"/ | ||
cp ./pom.xml ../../release/"${{github.event.inputs.name}}"/ | ||
cp ./README.md ../../release/"${{github.event.inputs.name}}"/ | ||
cp ./specs.yaml ../../release/"${{github.event.inputs.name}}"/specs.yaml | ||
git checkout main | ||
git pull | ||
git checkout -b "${{github.event.inputs.name}}-${{github.event.inputs.version}}" | ||
git add ../../release/\* | ||
git commit -m "chore: Publish ${{github.event.inputs.name}} [${{github.event.inputs.version}}] SDK" | ||
git push --set-upstream origin "${{github.event.inputs.name}}-${{github.event.inputs.version}}" | ||
gh pr create -B main -H "${{github.event.inputs.name}}-${{github.event.inputs.version}}" --title 'chore: Publish ${{github.event.inputs.name}} [${{github.event.inputs.version}}] SDK' --fill | ||
env: | ||
GH_TOKEN: ${{ github.token }} |
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Transform Specs | ||
on: | ||
workflow_call: | ||
inputs: | ||
configurations: | ||
description: 'Spec Transformer CLI Configurations' | ||
type: string | ||
required: true | ||
|
||
jobs: | ||
transform-specs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: raw-specs | ||
- run: | | ||
npx --yes -p @expediagroup/spec-transformer cli ${{ inputs.configurations }} -i raw-specs.yaml -o specs.yaml | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
name: specs | ||
path: specs.yaml |
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