Update marketplace generated yaml with req/response examples #1
Workflow file for this run
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
name: Merge openapi request response examples | |
on: | |
pull_request: | |
paths: | |
- "docs/pages/api/marketplace/marketplace.gen.yaml" | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
name: Build and Push | |
steps: | |
- name: git-checkout | |
uses: actions/checkout@v4 | |
with: | |
lfs: true | |
- name: Install dependencies | |
run: | | |
npm install -g [email protected] | |
pnpm install | |
# Step 3: Get the list of changed files | |
- name: Get changed files | |
id: changes | |
run: | | |
git fetch origin ${{ github.base_ref }} | |
# List only the files that have changed between the current commit and the previous one | |
git diff --name-only HEAD^ HEAD > changed_files.txt | |
echo "Changed files:" | |
cat changed_files.txt | |
# Save the changed files to an output to be used later | |
echo "::set-output name=files::$(cat changed_files.txt)" | |
- name: Merge request and responses | |
run: | | |
# Read the changed files from the previous step | |
CHANGED_FILES=$(echo "${{ steps.changes.outputs.files }}" | tr '\n' ' ') | |