pdclark / git-plugin-updates

Enable WordPress automatic updates for plugins hosted on Github or Bitbucket.
70 stars 9 forks source link

Add short uri #25

Open afragen opened 11 years ago

afragen commented 11 years ago

I'll have to figure out how to add the <owner>/<repo> as an option for updating. To effect this the base URI would be placed from the header i.e.,

GitHub Plugin URI => https://github.com/ BitBucket Plugin URI => https://bitbucket.com/ etc.

pdclark commented 11 years ago

Is there an advantage to doing it this way when all the info can be detected by copying-and-pasting the repo URL?

I assume you're talking about a format like this? GitHub URI: brainstormmedia/git-plugin-updates

Is this for compatibility with something that's already out there?

afragen commented 11 years ago

Well github-updater supports it :wink:

It was a feature request from @GaryJones

afragen commented 11 years ago

The BIG advantage I can see is so that any .org hosted plugin whose development is on GitHub or BitBucket doesn't get flagged for updating because of the plugin. WP.org repo plugins should only get an update instruction for .org

pdclark commented 11 years ago

This is still confusing to me. Maybe we could chat on Skype?

If the purpose is to provide two ways to configure the updater, it seems redundant.

If the purpose it to display a link to Git without firing updates, I think that's better done in a GUI and left up to the user — the plugin's only going to update if the readme version is bumped anyway.

pdclark commented 11 years ago

Or put another way, what is the problem this solves?

/*
Plugin URI: http://wordpress.org/someplugin
Git URI: http://github.com/owner/someplugin
*/

/*
Plugin URI: http://wordpress.org/someplugin
Git(hub) URI: owner/someplugin
*/

These both do the same thing, except that now a user can't copy-and-paste a link, and the definition of URI is being ignored.

afragen commented 11 years ago

I'm on call today so Skype won't work but here's where it causes an issue.

Plugin URI: https://github.com/afragen/events-calendar-category-colors

This is what I have had as the Plugin URI for a at least 2 years. As a test I decreased the version number an this plugin updated it, not the repo.

pdclark commented 11 years ago

Plugin URI should be fixed (disabled) in this commit: https://github.com/brainstormmedia/git-plugin-updates/commit/20fb1ac2228b484b7b59f35e684a5c2410ce6cc7

Can you tell me a bit more about supporting owner/repo in the Git URI field? Is it just for shorthand?

pdclark commented 11 years ago

(Or, just link me to @GaryJones's original feature request.)

GaryJones commented 11 years ago

The gist of it was, we had something like:

GitHub URL: https://github.com/.../...

The domain was redundant, since we'd already specified "GitHub" as the plugin header.

pdclark commented 11 years ago

If you want to submit a pull request to allow that with the legacy headers, I'll accept it. As long as we don't document it as an option.

It'd also be fine for Git URI: to assume Github if no domain, but again, would rather not document that it allows for that. I think providing two options to config to do the same thing adds confusion (and it's not what a URI is!).