Skip to content
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

Publish to packagist 🙏 #823

Closed
roborourke opened this issue Mar 5, 2021 · 2 comments
Closed

Publish to packagist 🙏 #823

roborourke opened this issue Mar 5, 2021 · 2 comments

Comments

@roborourke
Copy link
Contributor

roborourke commented Mar 5, 2021

Describe the problem you'd like to have solved

Hey, I was wondering if you would consider publishing this plugin to packagist.org too? Great to see it you have it set up for wpackagist but I have a use-case where that isn't an option.

If I wanted to have this plugin as a dependency of another package then I have to get it from packagist.org as dependencies can't specify custom repositories in their composer.json.

Describe the ideal solution

It looks like there's no extra build step beyond installing composer dependencies which wouldn't be needed for a packagist install.

From what I can tell the line that includes the vendor/autoload.php just needs to wrapped in a file exists check eg:

if ( is_readable( __DIR__ . '/vendor/autoload.php' ) ) {
    require_once __DIR__ . '/vendor/autoload.php';
}

If you approve of the idea and it doesn't require any further complex build processes (thinking client side assets) then I'm happy to make the PR for the above change.

@evansims
Copy link
Member

evansims commented Mar 8, 2021

Hey, @roborourke 👋 Thanks for the suggestion! That request makes perfect sense to me. If you'd like to put a PR together for that it'd be greatly appreciated!

roborourke added a commit to roborourke/wp-auth0 that referenced this issue Mar 8, 2021
Enables publishing this plugin to Packagist, raised in auth0#823 

Packagist installs will use the project `vendor` directory rather than requiring the plugin to bundle it.
evansims added a commit that referenced this issue Mar 8, 2021
* Support installation via Packagist

Enables publishing this plugin to Packagist, raised in #823 

Packagist installs will use the project `vendor` directory rather than requiring the plugin to bundle it.

* Fix linter error

Co-authored-by: Evan Sims <[email protected]>
@evansims
Copy link
Member

evansims commented Mar 8, 2021

Merged, thanks!

@evansims evansims closed this as completed Mar 8, 2021
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 19, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants