DEV Community

Dimitrios Desyllas
Dimitrios Desyllas

Posted on

Can I commit changes and push changes into my vendor if I use vcs as composer repository?

I am looking a way to manage the dependencies that I develop and use at the same time in multiple projects:

I have the following composer.json:

{
    "repositories":[
      {
        "type": "vcs",
        "url": "git@github.com:vendor/secret.git"
      }
    ],
    "deps":{
       "foo/bar":"dev-master#1.1",
       "bar/baz":"dev-master#1.2"
    },
    "config": {
        "preferred-install": {
            "foo/bar": "source",
            "bar/baz": "source",
            "*": "dist"
        }
    }
}

And I am the developer of both foo/bar and bar/baz dependencies. If I want to do a change…

What I want is to develop a new dependency version and tag it and update by cding into vendor folder and commit my changes.

Can you help me with that?

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay