-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vendor Expose fails when referencing repositories of type path #34
Comments
Have you tried using the "copy" strategy rather than symlink for the vendor-expose command? I'm not sure it would make a difference, but worth checking. Also another thing to check is whether silverstripe/silverstripe-framework#9569 might fix this. |
Yeah, I don't think this composer plugin relies on Silverstripe core concepts such as module manifest, but I could be mistaken. |
I tried with a really simple version of this:
"repositories": [
{
"type": "path",
"url": "../silverstripe-module"
}
],
and everything looked right. I'm running WSL (debian) and OP was running Laravel Homestead through Vagrant, so it's possible there was a weird file sync or mount issue or something, because they were able to fix it with a clean install. |
bug definitely still present, just ran into this issue on linux |
ok, I think I've identified the problem: it happens when a module is developed outside of the project and synced into the project using symlinks (which is afaik the recommended way to develop modules). So: "repositories": {
"silverstripe-foo-module": {
"type": "path",
"url": "../srv/some-long-path/silverstripe-foo-module",
"options": {
"symlink": true
}
}
} What I happens is:
Work around: don't use symlink for adding the module to your project. "repositories": {
"silverstripe-foo-module": {
"type": "path",
"url": "../srv/some-long-path/silverstripe-foo-module",
"options": {
"symlink": false
}
}
} |
As a weird side note I've used This worked as I tend not to update ( It also depends on composer knowing it's a |
still an issue with |
vendor-plugin/src/Library.php
Lines 47 to 52 in 87769ad
On a unix-like system symlinks are used by default.
https://getcomposer.org/doc/05-repositories.md#path
This leads
realpath
to be not what is expected (the module'sname
attribute), but instead the name of the linked local (e.g. development) repository. Vendor expose then creates a dud path where files exposed are then not found because of404
s.e.g. an exposure of
public/_resources/-dir/client/dist
forsomeone/module
, which may be actively being worked on and defined as below to avoid continual necessitation of commits and pushes:The text was updated successfully, but these errors were encountered: