I am using Laravel 5.2.23 and am unable to pull in my new package, bsapaka/metattribute. I get the exception:
[InvalidArgumentException]
Could not find package bsapaka/metattribute at any version for your minimum-stability (stable). Check the package spelling or your minimum-stability
Composer seems to have it:
Running composer show bsapaka/metattribute
returns:
name : bsapaka/metattribute
descrip. : classes for Laravel attributes
keywords : attribute, attributes, properties, alias, meta attribute
versions : dev-master
type : library
(more)
So I am wondering if I am missing something in the composer.json
:
{
"name": "bsapaka/metattribute",
"type": "library",
"description": "classes for Laravel attributes",
"keywords": [
"attribute",
"attributes",
"properties",
"meta attribute",
"alias"
],
"homepage": "https://github.com/bsapaka/metattribute",
"license": "MIT",
"require": {
"illuminate/support": "~5.1",
"php" : "~5.5|~7.0"
},
"require-dev": {
"phpspec/phpspec": "~2.2"
},
"autoload": {
"psr-4": {
"bsapaka\\metattribute\\": "src/"
}
},
"minimum-stability": "stable"
}
I have done a good bit of docs reading, troubleshooting, adding in mininum-stability
, checking the versioning, comparing against other packages, validating JSON, looking for the tidbits I missed etc, and at this point I could really use some guidance on where I might be going wrong. Thanks for reading, and I appreciate your help.
You don't have any version tag defined in your master
branch on GitHub.
If there is no version tag then Composer doesn't know which version is the stable one. So if you have "minimum-stability": "stable"
in the project which is requiring your self made package it can't find any stable version.
Create a new tag (e.g. 1.0.0) in your master branch on GitHub to declare the latest commit as stable or use the dev-master
version and "minimum-stability": "dev"
in the project which is requiring your self made package.