Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fix up require so it works for dev and pear

  • Loading branch information...
commit 4102f7e7c31e323ede79c64bc832de4905c04a58 1 parent 3bc6c27
@apinstein authored
Showing with 28 additions and 1 deletion.
  1. +2 −0  .gitignore
  2. +9 −1 iphp
  3. +17 −0 pearfarm.spec
View
2  .gitignore
@@ -0,0 +1,2 @@
+package.xml
+iphp-*.tgz
View
10 iphp
@@ -2,7 +2,15 @@
<?php
ini_set('memory_limit', '20M');
-require_once dirname(__FILE__).DIRECTORY_SEPARATOR.'iphp.php';
+if (strpos('@php_bin@', '@php_bin') === 0) // not a pear install
+{
+ require_once dirname(__FILE__).DIRECTORY_SEPARATOR.'iphp.php';
+}
+else
+{
+ require_once 'iphp'.DIRECTORY_SEPARATOR.'iphp.php';
+}
+
$opts = array();
View
17 pearfarm.spec
@@ -0,0 +1,17 @@
+<?php
+
+$spec = PEARFarm_Specification::newSpec(array(PEARFarm_Specification::OPT_BASEDIR => dirname(__FILE__)))
+ ->setName('iphp')
+ ->setChannel('pear.nimblize.com')
+ ->setSummary('PHP Shell')
+ ->setDescription('An interactive PHP Shell (or Console, or REPL).')
+ ->setReleaseVersion('1.0.0')
+ ->setReleaseStability('stable')
+ ->setApiVersion('1.0.0')
+ ->setApiStability('stable')
+ ->setLicense(PEARFarm_Specification::LICENSE_MIT)
+ ->setNotes('First release of iphp.')
+ ->addMaintainer('lead', 'Alan Pinstein', 'apinstein', 'apinstein@mac.com')
+ ->addGitFiles()
+ ->addExecutable('iphp')
+ ;
Please sign in to comment.
Something went wrong with that request. Please try again.