Making WordPress.org

Changeset 4727


Ignore:
Timestamp:
01/19/2017 04:33:23 AM (10 years ago)
Author:
dd32
Message:

Plugin Directory: Add a custom table containing a subset of plugin meta used for api.wordpress.org/plugins/update-check/.

See #2112

Location:
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory
Files:
1 added
3 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/cli/class-import.php

    r4657 r4727  
    44use WordPressdotorg\Plugin_Directory\Readme\Parser;
    55use WordPressdotorg\Plugin_Directory\Template;
     6use WordPressdotorg\Plugin_Directory\Jobs\API_Update_Updater;
    67use WordPressdotorg\Plugin_Directory\Tools;
    78use WordPressdotorg\Plugin_Directory\Tools\Filesystem;
     
    193194                // Finally, set the new version live.
    194195                update_post_meta( $plugin->ID, 'stable_tag', $stable_tag );
     196
     197                // Ensure that the API gets the updated data
     198                API_Update_Updater::update_single_plugin( $plugin->post_name );
    195199
    196200                return true;
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/jobs/class-manager.php

    r4523 r4727  
    1919
    2020                // The actual cron hooks.
    21                 add_action( 'plugin_directory_meta_sync', array( __NAMESPACE__ . '\Meta_Sync', 'cron_trigger' ) );
    22                 add_action( 'plugin_directory_svn_sync',  array( __NAMESPACE__ . '\SVN_Watcher', 'cron_trigger' ) );
    23                
     21                add_action( 'plugin_directory_meta_sync',        array( __NAMESPACE__ . '\Meta_Sync', 'cron_trigger' ) );
     22                add_action( 'plugin_directory_svn_sync',         array( __NAMESPACE__ . '\SVN_Watcher', 'cron_trigger' ) );
     23                add_action( 'plugin_directory_update_api_check', array( __NAMESPACE__ . '\API_Update_Updater', 'cron_trigger' ) );
    2424
    2525                // Register the wildcard cron hook tasks.
     
    134134                        wp_schedule_event( time(), 'every_30s', 'plugin_directory_svn_sync' );
    135135                }
     136                if ( ! wp_next_scheduled ( 'plugin_directory_update_api_check' ) ) {
     137                        wp_schedule_event( time(), 'hourly', 'plugin_directory_update_api_check' );
     138                }
    136139        }
    137140
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/zip/class-builder.php

    r3321 r4727  
    202202                $this->exec( sprintf(
    203203                        'mv -f %s %s',
    204                         $this->tmp_build_file,
    205                         $this->zip_file
     204                        escapeshellarg( $this->tmp_build_file ),
     205                        escapeshellarg( $this->zip_file )
    206206                ), $output, $return_value );
    207207
Note: See TracChangeset for help on using the changeset viewer.