L
L
Leopandro2015-12-07 18:37:01
Yii
Leopandro, 2015-12-07 18:37:01

How to make composer use my fork?

I did a fork, then made changes to the dev-master-modify branch, now I have to add my branch to the composer.
Host repository: https://github.com/dektrium/yii2-user
My repository: https://github.com/Leopandro/yii2-user
Here you can see that I have this branch: https://github.com /Leopandro/yii2-user/network
How to do it?
i tried to do this:

"repositories":
    [
        {
            "type": "vcs",
            "url": "https://github.com/Leopandro/yii2-user"
        }
    ],
"require": {
"dektrium/yii2-user": "dev-master-modify",
},

The second day I'm already fumbling,
I get a message:
- The requested package dektrium/yii2-user dev-master-modify could not be found.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
L
Leopandro, 2015-12-07
@Leopandro

It was necessary to change "dev-master-modify" to "master". OH JAAAAAAAA I DID IT!!!!!!! FINALLY!!

D
Dmitry Entelis, 2015-12-07
@DmitriyEntelis

So maybe Leopandro/yii2-user after all?

S
sokollondon, 2017-02-09
@sokollondon

You don't need to create a new branch in your fork. It is enough to specify "dektrium/yii2-user": "dev-master",and composer will pull up the "master" branch of your fork.
More code:

"repositories": [
  {
    "type": "vcs",
    "url": "https://github.com/Leopandro/yii2-user"
  }
],
"require": {
  "dektrium/yii2-user": "dev-master",
},

Update by team
php composer.phar update dektrium/yii2-user

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question