当前位置: 首页>>代码示例>>PHP>>正文


PHP LibraryInstaller::removeCode方法代码示例

本文整理汇总了PHP中Composer\Installer\LibraryInstaller::removeCode方法的典型用法代码示例。如果您正苦于以下问题:PHP LibraryInstaller::removeCode方法的具体用法?PHP LibraryInstaller::removeCode怎么用?PHP LibraryInstaller::removeCode使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Composer\Installer\LibraryInstaller的用法示例。


在下文中一共展示了LibraryInstaller::removeCode方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: removeCode

 /**
  * {@inheritDoc}
  */
 protected function removeCode(PackageInterface $package)
 {
     $path = $this->getInstallPath($package);
     if ($this->isSymlink($path)) {
         $this->debug("Unlinking <comment>{$path}</comment>...");
         $this->filesystem->unlink($path);
         return true;
     }
     return parent::removeCode($package);
 }
开发者ID:far-blue,项目名称:dev-linker,代码行数:13,代码来源:DevLinker.php

示例2: removeCode

 /**
  * {@inheritDoc}
  */
 protected function removeCode(PackageInterface $package)
 {
     $publicPath = $this->getPublicPath();
     $installPath = $this->getInstallPath($package);
     if (is_link($installPath)) {
         unlink($installPath);
     } else {
         parent::removeCode($package);
     }
     // remove symlink package public folder to keeko's public folder
     $type = $package->getType();
     if ($type !== 'keeko-core') {
         $target = $this->filesystem->normalizePath($publicPath . '/' . $this->getPackageDir($type) . '/' . $package->getName());
         if (is_link($target)) {
             unlink($target);
         }
         // remove parent if empty
         $parent = dirname($target);
         if (file_exists($parent) && count(scandir($parent)) == 2) {
             $this->filesystem->removeDirectoryPhp($parent);
         }
     }
 }
开发者ID:JasLin,项目名称:composer-installer,代码行数:26,代码来源:KeekoComposerInstaller.php

示例3: removeCode

 /**
  * {@inheritDoc}
  */
 protected function removeCode(PackageInterface $package)
 {
     parent::removeCode($package);
     $this->removeLoader($package);
 }
开发者ID:devaloka,项目名称:mu-plugin-installer,代码行数:8,代码来源:MuPluginInstaller.php

示例4: removeCode

 /**
  * {@inheritDoc}
  */
 protected function removeCode(PackageInterface $package)
 {
     if ($this->isLocalSymlink($package)) {
         $this->filesystem->unlink($this->getInstallPath($package));
         return true;
     }
     return parent::removeCode($package);
 }
开发者ID:piwi,项目名称:composer-symlinker,代码行数:11,代码来源:LocalInstaller.php

示例5: removeCode

 /**
  * Remove both the installed code and files from the Component directory.
  *
  * @param PackageInterface $package
  */
 public function removeCode(PackageInterface $package)
 {
     $this->removeComponent($package);
     parent::removeCode($package);
 }
开发者ID:robloach,项目名称:component-installer,代码行数:10,代码来源:Installer.php

示例6: removeCode

 /**
  * {@inheritDoc}
  */
 protected function removeCode(PackageInterface $package)
 {
     if (!$this->isSharedInstallEnabled($package)) {
         parent::removeCode($package);
         return;
     }
 }
开发者ID:ngyuki,项目名称:composer-shared-installer,代码行数:10,代码来源:Installer.php

示例7: removeCode

 /**
  * Remove the code
  *
  * @param PackageInterface $package            
  * @return void
  */
 public function removeCode(PackageInterface $package)
 {
     $this->initializeVendorDir();
     $this->supportedByName($package->getPrettyName());
     $this->setComponentPath();
     if (is_dir($this->getComponentPath()) && basename($this->getComponentPath()) !== 'component') {
         $this->filesystem->removeDirectory($this->getComponentPath());
     } else {
         $this->io->error($this->getComponentPath());
     }
     parent::removeCode($package);
 }
开发者ID:mkungla,项目名称:aframe-php,代码行数:18,代码来源:AframeComponentInstaller.php


注:本文中的Composer\Installer\LibraryInstaller::removeCode方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。