contao / contao-manager

Contao Manager
GNU Lesser General Public License v3.0
85 stars 33 forks source link

[Feature]: Unterstützung von glob-Patterns in "repositories"-Sektion #633

Closed MacGyer closed 2 years ago

MacGyer commented 3 years ago

Hallo,

da ich aktuell mehrere Extensions für eine Contao-Instanz entwickele, habe ich die Angabe zum lokalen Spiegeln der Pakete im Composer-Schema mit einem glob-Pattern * angegeben. Dies ist von Composer direkt so vorgesehen (https://getcomposer.org/doc/05-repositories.md#path; Siehe letzte Notiz), leider kann der Manager mit aktivierter Resolver-Cloud damit nicht umgehen.

"repositories": [
    {
        "type": "path",
        "url": "vendor_static/bundles/*",
        "options": {
            "symlink": true
        }
    },
],

Ist Support für glob-Patterns geplant?

Cheers

fritzmg commented 3 years ago

The problem is not the glob pattern but the fact that you are using a local bundle. The resolver cloud has of course no access to these bundles. If yo use local bundles, you cannot use the resolver cloud.

MacGyer commented 3 years ago

The following is working with resolver cloud:

"repositories": [
    {
        "type": "path",
        "url": "vendor_static/bundles/bundle-1",
        "options": {
            "symlink": true
        }
    },
    {
        "type": "path",
        "url": "vendor_static/bundles/bundle-2",
        "options": {
            "symlink": true
        }
    },
],

So if I am specifying each local bundle with a path to the exact folder (relative to composer.json) the resolving is working like expected. Only using the glob pattern is not working.

Any thoughts?

fritzmg commented 3 years ago

I wasn't aware that that works. @aschempp is the Contao Manager somehow sending information about the local bundles to the resolver cloud now?

aschempp commented 3 years ago

yes, it is sending the content of composer.json of artifact and path repositories to the cloud to resolve its dependencies. That's how the ZIP upload works. I wasn't ware you can use glob patterns for the path, so that's not (yet) supported. Sure is something we can add though I guess 😊

MacGyer commented 3 years ago

Thx for getting back and checking out the possibilities.

Have a nice weekend.

aschempp commented 2 years ago

I just tried this locally and the resolve cloud seems to receive the correct repository results. I would therefore assume this has been fixed (e.g. in Composer 2.2) or is a cloud issue. I'm closing this for now, feel free to response/reopen if the issue still exists.