hoauth icon indicating copy to clipboard operation
hoauth copied to clipboard

please add to packagist/composer

Open cornernote opened this issue 10 years ago • 9 comments

This will allow simple installation outside of my application's path. Let me know if you need a sample composer.json and I will do a pull request.

cornernote avatar May 24 '14 13:05 cornernote

Hi, @cornernote so I simply need to commit something like this:

{
    "name": "sleepwalker/hoauth",
}

and than simply add my project to packagist, am I right?

P.S. I don't want to add hybridauth as dependency now. I will make a huge update, when I finally will be ready with my university and than I'll use the latest version of hybridauth, witch is very active maintained at the moment!

SleepWalker avatar May 24 '14 20:05 SleepWalker

Yep, that should do it. You need to remove the comma otherwise it's not valid json.

cornernote avatar May 26 '14 08:05 cornernote

oh, yes. sorry) I have added the version number there before I have read that it is not required and after that introduced this mistake)

SleepWalker avatar May 27 '14 05:05 SleepWalker

I have added it. But packagist says that you need use "sleepwalker/hoauth": "dev-master" instead of "sleepwalker/hoauth": "1.2.4". Is it normal, or packagist sees no tags in my repo?

SleepWalker avatar May 27 '14 05:05 SleepWalker

You should add the dependency, you should lock it to a specific tag/release. When you update your code, you could update the dependent version too. https://github.com/hybridauth/hybridauth

Packagist should index all versions. Be sure to enable the update hook, see packagist profile page for details

RdeWilde avatar May 28 '14 09:05 RdeWilde

Maybe consider creating a seperate branch, as you should not directly include the hybridauth source into your own source. It would be managed through composer dependency.

RdeWilde avatar May 28 '14 09:05 RdeWilde

I understand it'll be a breaking change, but you could consider integrating into composer autoloading as Yii is also committing to the PSR* conventions which are also used by composer for generating the autoloader.

RdeWilde avatar May 28 '14 09:05 RdeWilde

HybridAuth I will make as dependency later, because at the moment in my repo the modificated version of old HybridAuth. And the new one version I should test, before I can write it as a dependency, so I will do that later, when I will have a little more time. It's okay so?

SleepWalker avatar May 28 '14 09:05 SleepWalker

I understand. Will fork.

You can actually fork the hybridauth repository to your own user. Add your changes to it (overwrite). Commit and push to your own fork. Include the original hybridauth as a dependency, but meanwhile add to your composer.json

"repositories" : [

        {
            "type": "git",
            "url": "https://github.com/hybridauth/hybridauth.git"
        }
]

This will overrule the dependency resolution to your own fork. You can control what version will be used in updates.

Side-effect is that your fork is actually mergeable with the original (both ways).

RdeWilde avatar May 28 '14 09:05 RdeWilde