Skip to content

Commit

Permalink
add error
Browse files Browse the repository at this point in the history
  • Loading branch information
withanage committed Jun 11, 2024
1 parent db18650 commit dbd8f68
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,20 +17,20 @@ jobs:
with:
node-version: 18

- name: Install Dependencies
- name: Install dependencies
run: |
sudo apt-get update -qq
sudo apt-get install libxml2-utils
npm install -g pkp-plugin-cli
shell: bash

- name: Clone pkp plugin gallery
- name: "Clone pkp/plugin-gallery"
run: |
cd ~
git clone https://github.com/pkp/plugin-gallery --depth 50
shell: bash

- name: Install for push
- name: Clone user plugin-gallery for push
if: ${{ github.event_name == 'push'}}
run: |
cd ~/${{github.event.pull_request.head.repo.name || github.event.repository.name }}
Expand All @@ -39,7 +39,7 @@ jobs:
git checkout -b user_repo/${{ github.head_ref || github.ref_name }}
shell: bash

- name: Install for pull_request
- name: lone user plugin-gallery for pull request
if: ${{github.event_name == 'pull_request'}}
run: |
cd ~/${{github.event.pull_request.head.repo.name || github.event.repository.name }}
Expand All @@ -48,20 +48,20 @@ jobs:
git checkout user_repo/${{ github.event.pull_request.head.ref}}
shell: bash

- name: "Run plugin validation"
- name: Validate against plugins.xd schema
run: |
cd ~/${{github.event.pull_request.head.repo.name || github.event.repository.name }}
xmllint --schema ./plugins.xsd ./plugins.xml --noout
shell: bash

- name: For push
- name: Validate all releases
if: ${{ github.event_name == 'push' && github.head_ref == 'main'}}
run: |
cd ~/${{github.event.pull_request.head.repo.name || github.event.repository.name }}
pkp-plugin validate-all-releases --input ./plugins.xml
shell: bash

- name: For pull request validate-new-release
- name: Validate new release
if: ${{ github.event_name == 'pull_request'}}
run: |
cd ~/${{github.event.pull_request.head.repo.name || github.event.repository.name }}
Expand All @@ -70,7 +70,7 @@ jobs:
pkp-plugin validate-new-release
shell: bash

- name: For push generate-site
- name: Generate site
if: ${{ github.event_name == 'push' && github.head_ref == 'main'}}
run: |
cd ~/${{github.event.pull_request.head.repo.name || github.event.repository.name }}
Expand Down

0 comments on commit dbd8f68

Please sign in to comment.