Skip to content
Snippets Groups Projects

Allow extension to be installed via Composer

Merged Ian_Edington requested to merge Ian_Edington/formprotection:patch-1 into main

Hi Form Protection team,

I would like to install civicrm/formprotection using Composer. I'm able to install this extension into the vendor package by using the following repository definition in Composer:

{
    "type": "vcs",
    "url": "https://lab.civicrm.org/civicrm/formprotection.git"
}

However, it installs into vendor/civicrm/formprotection.

Based on the CiviCRM's Composer guide it should be installed into web/sites/default/files/civicrm/ext/com.iatspayments.civicrm by using the following snippet to composer.json

"extra": {
    "installer-paths": {
        "web/sites/default/files/civicrm/ext/{$name}/": ["civicrm-ext"]
    }
}

However, this requires a change to this package's composer.json

  1. add a "type": "civicrm-ext" so Composer knows it's a CiviCRM extension and installs it into web/sites/default/files/civicrm/ext

I've made the required changes in this PR for your consideration.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading