Skip to content

Commit

Permalink
Create marketplace-upload.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
luke- authored Apr 13, 2022
1 parent 1220515 commit ac7c224
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/marketplace-upload.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
on:
push:
tags:
- 'v*'

name: Upload to HumHub Marketplace

jobs:
build:
name: Build and Upload Module Package
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
with:
path: ${{ github.event.repository.name }}

- name: Build project
run: |
zip -r ${{ github.event.repository.name }}.zip ${{ github.event.repository.name }}/
# - name: Install Composer
# run: cd ${{ github.event.repository.name }}; composer install --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi

# - name: Install NPM
# run: cd ${{ github.event.repository.name }}; npm install

- name: Upload Package to HumHub Marketplace
run: |
curl --fail \
-F "key=${{secrets.MARKETPLACE_API_KEY}}" \
-F "ModuleVersionUpload[zipFile]=@${{ github.event.repository.name }}.zip" \
https://api.humhub.com/v1/marketplace/upload?moduleId=${{ github.event.repository.name }}

0 comments on commit ac7c224

Please sign in to comment.