Browse Source

Merge pull request #3348 from jakoch/patch-isdryRun

added $installer->isDryRun()
Jordi Boggiano 10 years ago
parent
commit
ded4950433
1 changed files with 20 additions and 0 deletions
  1. 20 0
      src/Composer/Installer.php

+ 20 - 0
src/Composer/Installer.php

@@ -1052,6 +1052,16 @@ class Installer
         return $this;
     }
 
+    /**
+     * Checks, if this is a dry run (simulation mode).
+     *
+     * @return bool
+     */
+    public function isDryRun()
+    {
+        return $this->dryRun;
+    }
+
     /**
      * prefer source installation
      *
@@ -1156,6 +1166,16 @@ class Installer
         return $this;
     }
 
+    /**
+     * Checks, if running in verbose mode.
+     *
+     * @return bool
+     */
+    public function isVerbose()
+    {
+        return $this->verbose;
+    }
+
     /**
      * restrict the update operation to a few packages, all other packages
      * that are already installed will be kept at their current version