Skip to content

Mage Marketplace Package Converter

Actions
CustomGento Mage Marketplace Package Converter Action creates Marketplace-compatible packages from GitHub releases
v1.0.1
Latest
Star (6)

CustomGento Mage Marketplace Package Converter Action

CustomGento Mage Marketplace Package Converter Action creates Marketplace-compatible packages from GitHub releases.

Usually, code in PHP repositories is split into two directories src and tests. Unfortunately, Magento Marketplace does not support this structure. It expects you to put all your extension code into the root directory. To ease your release process, this action takes care of the conversion, so that you can directly upload a package in the right format to Magento Marketplace.

If you do not use a src directory in your repository, you do not need this action.

Each time you tag a new release, the action will convert your package to a Magento-Marketplace-compatible version. The following steps will be executed:

  1. All contents from the src directory will be moved to the root directory.
  2. In the composer.json, all references to the src directory will be removed.
  3. A zip-package will be created with the updated contents and added to your release.

Usage

  1. Create a personal access token under User Settings > Developer Settings > Personal access tokens with the scope repo and copy its value.

  2. In the repository settings under Secrets > Actions, create a new repository secret with the name ACCESS_TOKEN and the value from (1).

  3. In your repository, create a file .github/workflows/magento-marketplace.yml with the following contents:

     name: Publish
    
     on:
       push:
         tags:
           - '*'
    
     jobs:
       build:
         name: Publish Magento Marketplace Package
         runs-on: ubuntu-latest
    
         steps:
         - name: Create Marketplace Package
           uses: customgento/mage-marketplace-package-converter-action@main
           with:
             access_token: ${{ secrets.ACCESS_TOKEN }}
    

Feel free to adapt this default workflow to your needs.

Credits

Thanks to @svenstaro for his action to upload files to GitHub releases.

License

MIT License

Copyright

© 2022 - present CustomGento GmbH

Mage Marketplace Package Converter is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.

About

CustomGento Mage Marketplace Package Converter Action creates Marketplace-compatible packages from GitHub releases
v1.0.1
Latest

Mage Marketplace Package Converter is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.