I am trying add a Wordpress plugin from a Github Enterprise repo into my project. I have my wp-content folder within the root and my composer.json is as follows:
"repositories": [
{
"type": "package",
"package": {
"name": "name/plugin-name,
"type": "wordpress-plugin",
"version": "v1.0",
"dist": {
"type": "zip",
"url": "https://example.githubname.com/name/plugin-name/archive/v1.0.zip"
},
"require" : {
"composer/installers": "v1.0.21"
}
}
},
{
"type":"composer",
"url":"http://wpackagist.org"
}
],
"require": {
"name/plugin-name": "v1.0"
},
}
The following repository looks to unzip this repo and unpack it into the /wp-content/ folder.
I get the following error:
Loading composer repositories with package information
Updating dependencies (including require-dev)
- Installing name/plugin-name (v1.0)
Downloading: 100%
Invalid zip file, retrying...
- Installing name/plugin-name (v1.0)
Downloading: 100%
Invalid zip file, retrying...
- Installing name/plugin-name (v1.0)
Downloading: 100%
[UnexpectedValueException]
'wp-content/plugins/plugin-name//2b5746433a46375b233f5f91a9a69b43.zip' is not a zip archive.
It looks like the zip may be trying to authenticate via Github Enterprise. I tried removing ""url": "https://example.githubname.com/name/plugin-name/archive/v1.0.zip"" and adding a public facing repo like ""url": "https://github.com/WordPress/WordPress/archive/4.2.2.zip"" and it downloads into the plugin-name folder properly.
Is there something I can to for a github enterprise hosted wordpress plugin to be able to be extracted in the wp-content folder?