Hi I wanted to create an extension with the gii Extension Generator.
And wanted to test it only "locally".
Therefore i filled the fields with this values:
vendor: myself
packagename: yii2-foobar
namespace: myself\foobar\
type: yii2-extension
keywords: yii2,extension
title: foobar
output path: @vendor/myself
Because i wanted to test it only locally and not on git i added this to my composer.json file.
"repositories":[
{
"type": "git",
"url": "https://path.to/your/repo"
}
]
and replaced the url with the recommended value
Note: You may use the url file://D:\wamp\www\yii2\my_app\vendor\myself/yii2-foobar for testing.
OK i fixed the \ with \\
"url" : "file://D:\\wamp\\www\\yii2\\my_app\\vendor\\myself/yii2-foobar"
But always getting errors on composer update
[Composer\Repository\InvalidRepositoryException]
No valid composer.json was found in any branch or tag of file://D:/wamp/www/yii2/my_app/vendor/myself/yii2-foobar, could not load a package from it.
The path is correct and is the generated composer.json of the extension where i can’t find a problem.
Any hints?
Maybe the path is not correct on Windows Systems?
i also tried
"url" : "file://D:\\wamp\\www\\yii2\\my_app\\vendor\\myself\\yii2-foobar"
"url": "file://./vendor/myself/yii2-foobar"
"url" : "D:\\wamp\\www\\yii2\\my_app\\vendor\\myself/yii2-foobar"
"url" : "./vendor/myself/yii2-foobar"
"url" : "/vendor/myself/yii2-foobar"
"url" : "file://D:\\wamp\\www\\yii2\\my_app\\vendor\\myself/yii2-foobar"
So what is the correct path under windows or what could cause the problem?
regards Horizons