Packagist\Api\Result\Package::getRepository PHP Method

getRepository() public method

public getRepository ( ) : string
return string
    public function getRepository()
    {
        return $this->repository;
    }

Usage Example

Example #1
0
 /**
  * @param Package $package
  * @return array
  */
 public function transform(Package $package)
 {
     list($vendor, $name) = $this->splitVendorAndName($package->getName());
     $this->diskFactory->disk('local')->makeDirectory('storage/modules/' . $package->getName());
     if ($this->diskFactory->disk('local')->allDirectories('storage/modules/' . $package->getName()) === []) {
         $this->git->clone($package->getRepository(), storage_path('modules/' . $package->getName()));
     }
     return ['vendor' => $vendor, 'name' => $name, 'excerpt' => $package->getDescription(), 'description' => $this->getReadmeFileFor($package), 'favourites' => $package->getFavers(), 'total_downloads' => $package->getDownloads()->getTotal(), 'monthly_downloads' => $package->getDownloads()->getMonthly(), 'daily_downloads' => $package->getDownloads()->getDaily()];
 }
All Usage Examples Of Packagist\Api\Result\Package::getRepository