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

Update notice #418

Closed
BassemN opened this issue May 20, 2015 · 6 comments
Closed

Update notice #418

BassemN opened this issue May 20, 2015 · 6 comments

Comments

@BassemN
Copy link

BassemN commented May 20, 2015

Hello,
I'm using the latest version from the develop branch. Is there any way to display an admin notice if there are available updates for the bundled plugins?
Thanks

@jrfnl
Copy link
Contributor

jrfnl commented May 21, 2015

@BassemN Yes there is.
As the filename is the only info we have available and not all filenames contain version numbers and some may contain completely arbitrary other numbers, there is no way for TGMPA to know there is an update, so you need to add the version argument to the plugins array you're passing to TGMPA and set this to the new version you're including. So something along the lines of:

$plugins = array(
    array(
        'name'               => 'TGM Example Plugin', // The plugin name.
        'slug'                 => 'tgm-example-plugin',
        'source'             => get_stylesheet_directory() . '/lib/plugins/tgm-example-plugin.zip',
        'required'           => true,
        'version'             => '1.1.0',
    ),
);

Hope this helps.

@jrfnl jrfnl closed this as completed May 21, 2015
@GaryJones
Copy link
Member

@jrfnl If it's not already, this needs to be in the new FAQ so you can easily point to it :-)

@BassemN
Copy link
Author

BassemN commented May 21, 2015

@jrfnl thanks for your reply.
I did this already and no admin notice is displayed when there is an update.
I think my issue related to issue #353

@jrfnl
Copy link
Contributor

jrfnl commented May 21, 2015

@BassemN Ah, then that's another issue and with #353 being open, it will be addressed (at some point).

@GaryJones It already is + has this info on the configuration page with the parameter explanation.

@BassemN
Copy link
Author

BassemN commented May 21, 2015

@jrfnl so I think you should move issue #353 to 2.5 milestone

@jrfnl
Copy link
Contributor

jrfnl commented May 22, 2015

@BassemN While I agree that it needs to be addressed, I think you might underestimate the complexity of it. The way plugins are registered now, I don't see much possibility to really get it working as it should. With the changes we propose in the v3.0 roadmap #394 I believe we can address this properly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants