Пример #1
0
 /**
  * Runs the import process for a provided sha.
  *
  * @param string $sha
  */
 public function run($sha)
 {
     $this->tree->fetch_sha($sha);
     if (!$this->tree->ready()) {
         WordPress_GitHub_Sync::write_log(__('Failed getting recursive tree with error: ', 'wordpress-github-sync') . $this->tree->last_error());
         return;
     }
     foreach ($this->tree as $blob) {
         $this->import_blob($blob);
     }
     WordPress_GitHub_Sync::write_log(__('Imported tree ', 'wordpress-github-sync') . $sha);
 }