Skip to content

Commit

Permalink
[1.5] Changed references to phpdb.org to propelorm.org, updated the P…
Browse files Browse the repository at this point in the history
…EAR builders accordingly
  • Loading branch information
fzaninotto committed Apr 16, 2010
1 parent 2f790ef commit 05357dd
Show file tree
Hide file tree
Showing 10 changed files with 76 additions and 53 deletions.
24 changes: 14 additions & 10 deletions docs/guide/01-Installation.txt
Expand Up @@ -27,13 +27,13 @@ Usually, both the generator and the runtime components are installed on developm

=== Installing Propel From PEAR ===

In order to install the Propel packages, you must add the `pear.phpdb.org` channel to your PEAR environment. Once the channel is discovered, you can install the generator package, or the runtime package, or both. Use the '-a' option to let PEAR download and install dependencies.
In order to install the Propel packages, you must add the `pear.propelorm.org` channel to your PEAR environment. Once the channel is discovered, you can install the generator package, or the runtime package, or both. Use the '-a' option to let PEAR download and install dependencies.

{{{
#!sh
> pear channel-discover pear.phpdb.org
> pear install -a phpdb/propel_generator
> pear install -a phpdb/propel_runtime
> pear channel-discover pear.propelorm.org
> pear install -a propelorm/propel_generator
> pear install -a propelorm/propel_runtime
}}}

Propel is now installed, and you can test it by following the instructions of the '''Testing Propel Installation''' section at the end of this page.
Expand Down Expand Up @@ -66,7 +66,7 @@ Installing from SVN trunk ensures that you have the most up-to-date source code.

{{{
#!sh
> svn checkout http://svn.phpdb.org/propel/branches/1.5 /usr/local/propel
> svn checkout http://svn.propelorm.org/branches/1.5 /usr/local/propel
}}}

This will export both the generator and runtime components to your local `propel` directory. In addition, you'll also get Propel documentation and unit tests - that's why this method is the preferred installation method for Propel contributors.
Expand All @@ -84,9 +84,9 @@ Download a tarball of each of the Propel components from the Propel website, and
> cd /usr/local
> mkdir propel
> cd propel
> wget http://pear.phpdb.org/get/propel_generator-1.5.0.tgz
> wget http://pear.propelorm.org/get/propel_generator-1.5.0.tgz
> tar zxvf propel_generator-1.5.0.tgz
> wget http://pear.phpdb.org/get/propel_runtime-1.5.0.tgz
> wget http://pear.propelorm.org/get/propel_runtime-1.5.0.tgz
> tar zxvf propel_runtime-1.5.0.tgz
}}}

Expand Down Expand Up @@ -123,7 +123,7 @@ In order to allow an easier execution the script, you can also:

Propel requires that the runtime classes are in PHP `include_path`.

The easiest and most permanent way to set your `include_path` is to simply edit your `php.ini` file and add the `propel/runctime/classes/` directory to the `include_path` variable:
The easiest and most permanent way to set your `include_path` is to simply edit your `php.ini` file and add the `propel/runtime/classes/` directory to the `include_path` variable:

{{{
; Unix
Expand Down Expand Up @@ -165,9 +165,13 @@ You can test that the '''Propel runtime''' component is properly installed by re
{{{
#!php
<?php
set_include_path("/usr/local/propel/runtime/classes" . PATH_SEPARATOR . get_include_path());

// PEAR installation
require_once 'propel/Propel.php';

// manual installation
set_include_path("/usr/local/propel/runtime/lib" . PATH_SEPARATOR . get_include_path());
require_once 'Propel.php';

// Propel setup code ... (to be discussed later)
}}}

Expand Down
2 changes: 1 addition & 1 deletion docs/guide/08-Logging.txt
Expand Up @@ -397,7 +397,7 @@ The following settings can be customized at runtime or in the configuration file
||`debugpdo.logging.innerglue`||`": "`||String to use for combining the title of a detail and its value||
||`debugpdo.logging.outerglue`||`" | "`||String to use for combining details together on a log line||
||`debugpdo.logging.realmemoryusage`||`false`||Parameter to [http://www.php.net/manual/en/function.memory-get-usage.php memory_get_usage()] and [http://www.php.net/manual/en/function.memory-get-peak-usage.php memory_get_peak_usage()] calls||
||`debugpdo.logging.methods`||[http://propel.phpdb.org/trac/browser/branches/1.5/runtime/classes/propel/util/DebugPDO.php#L151 array(...)]||An array of method names `Class::method`) to be included in method call logging||
||`debugpdo.logging.methods`||[http://propel.propelorm.org/browser/branches/1.5/runtime/classes/propel/util/DebugPDO.php#L151 array(...)]||An array of method names `Class::method`) to be included in method call logging||
||`debugpdo.logging.details.slow.enabled`||`false`||Enables flagging of slow method calls||
||`debugpdo.logging.details.slow.threshold`||`0.1`||Method calls taking more seconds than this threshold are considered slow||
||`debugpdo.logging.details.time.enabled`||`false`||Enables logging of method execution times||
Expand Down
10 changes: 5 additions & 5 deletions generator/lib/builder/om/PHP5PeerBuilder.php
Expand Up @@ -999,7 +999,7 @@ public static function populateObjects(PDOStatement \$stmt)
\$key = ".$this->getPeerClassname()."::getPrimaryKeyHashFromRow(\$row, 0);
if (null !== (\$obj = ".$this->getPeerClassname()."::getInstanceFromPool(\$key))) {
// We no longer rehydrate the object, since this can cause data loss.
// See http://propel.phpdb.org/trac/ticket/509
// See http://www.propelorm.org/ticket/509
// \$obj->hydrate(\$row, 0, true); // rehydrate
\$results[] = \$obj;
} else {";
Expand Down Expand Up @@ -1049,7 +1049,7 @@ public static function populateObject(\$row, \$startcol = 0)
\$key = ".$this->getPeerClassname()."::getPrimaryKeyHashFromRow(\$row, \$startcol);
if (null !== (\$obj = ".$this->getPeerClassname()."::getInstanceFromPool(\$key))) {
// We no longer rehydrate the object, since this can cause data loss.
// See http://propel.phpdb.org/trac/ticket/509
// See http://www.propelorm.org/ticket/509
// \$obj->hydrate(\$row, \$startcol, true); // rehydrate
\$col = \$startcol + " . $this->getPeerClassname() . "::NUM_COLUMNS;";
if ($table->isAbstract()) {
Expand Down Expand Up @@ -2039,7 +2039,7 @@ public static function doSelectJoin".$thisTableObjectBuilder->getFKPhpNameAffix(
\$key1 = ".$this->getPeerClassname()."::getPrimaryKeyHashFromRow(\$row, 0);
if (null !== (\$obj1 = ".$this->getPeerClassname()."::getInstanceFromPool(\$key1))) {
// We no longer rehydrate the object, since this can cause data loss.
// See http://propel.phpdb.org/trac/ticket/509
// See http://www.propelorm.org/ticket/509
// \$obj1->hydrate(\$row, 0, true); // rehydrate
} else {
";
Expand Down Expand Up @@ -2271,7 +2271,7 @@ public static function doSelectJoinAll(Criteria \$criteria, \$con = null, \$join
\$key1 = ".$this->getPeerClassname()."::getPrimaryKeyHashFromRow(\$row, 0);
if (null !== (\$obj1 = ".$this->getPeerClassname()."::getInstanceFromPool(\$key1))) {
// We no longer rehydrate the object, since this can cause data loss.
// See http://propel.phpdb.org/trac/ticket/509
// See http://www.propelorm.org/ticket/509
// \$obj1->hydrate(\$row, 0, true); // rehydrate
} else {";

Expand Down Expand Up @@ -2542,7 +2542,7 @@ public static function doSelectJoinAllExcept".$thisTableObjectBuilder->getFKPhpN
\$key1 = ".$this->getPeerClassname()."::getPrimaryKeyHashFromRow(\$row, 0);
if (null !== (\$obj1 = ".$this->getPeerClassname()."::getInstanceFromPool(\$key1))) {
// We no longer rehydrate the object, since this can cause data loss.
// See http://propel.phpdb.org/trac/ticket/509
// See http://www.propelorm.org/ticket/509
// \$obj1->hydrate(\$row, 0, true); // rehydrate
} else {";
if ($table->getChildrenColumn()) {
Expand Down
39 changes: 24 additions & 15 deletions generator/pear/BuildPropelGenPEARPackageTask.php
Expand Up @@ -37,7 +37,8 @@
* @package phing.tasks.ext
* @version $Revision$
*/
class BuildPropelGenPEARPackageTask extends MatchingTask {
class BuildPropelGenPEARPackageTask extends MatchingTask
{

/** Base directory for reading files. */
private $dir;
Expand All @@ -51,15 +52,16 @@ class BuildPropelGenPEARPackageTask extends MatchingTask {
/** Package file */
private $packageFile;

public function init() {
public function init()
{
include_once 'PEAR/PackageFileManager2.php';
if (!class_exists('PEAR_PackageFileManager2')) {
throw new BuildException("You must have installed PEAR_PackageFileManager2 (PEAR_PackageFileManager >= 1.6.0) in order to create a PEAR package.xml file.");
}
}

private function setOptions($pkg){

private function setOptions($pkg)
{
$options['baseinstalldir'] = 'propel';
$options['packagedirectory'] = $this->dir->getAbsolutePath();

Expand Down Expand Up @@ -108,8 +110,8 @@ private function setOptions($pkg){
* Main entry point.
* @return void
*/
public function main() {

public function main()
{
if ($this->dir === null) {
throw new BuildException("You must specify the \"dir\" attribute for PEAR package task.");
}
Expand All @@ -126,7 +128,7 @@ public function main() {
$package->setPackage('propel_generator');
$package->setSummary('Generator component of the Propel PHP object persistence layer');
$package->setDescription('Propel is an object persistence layer for PHP5 based on Apache Torque. This package provides the generator engine that builds PHP classes and SQL DDL based on an XML representation of your data model.');
$package->setChannel('pear.phpdb.org');
$package->setChannel('pear.propelorm.org');
$package->setPackageType('php');

$package->setReleaseVersion($this->version);
Expand Down Expand Up @@ -160,7 +162,7 @@ public function main() {
$package->setPearinstallerDep('1.4.0');

// "package" dependencies
$package->addPackageDepWithChannel( 'required', 'phing', 'pear.phing.info', '2.3.0');
$package->addPackageDepWithChannel('required', 'phing', 'pear.phing.info', '2.3.0');

$package->addExtensionDep('required', 'pdo');
$package->addExtensionDep('required', 'xml');
Expand All @@ -186,7 +188,8 @@ public function main() {
* Used by the PEAR_PackageFileManager_PhingFileSet lister.
* @return array FileSet[]
*/
public function getFileSets() {
public function getFileSets()
{
return $this->filesets;
}

Expand All @@ -199,7 +202,8 @@ public function getFileSets() {
*
* @return FileSet The created fileset object
*/
function createFileSet() {
function createFileSet()
{
$num = array_push($this->filesets, new FileSet());
return $this->filesets[$num-1];
}
Expand All @@ -209,7 +213,8 @@ function createFileSet() {
* @param string $v
* @return void
*/
public function setVersion($v){
public function setVersion($v)
{
$this->version = $v;
}

Expand All @@ -218,7 +223,8 @@ public function setVersion($v){
* @param string $v
* @return void
*/
public function setState($v) {
public function setState($v)
{
$this->state = $v;
}

Expand All @@ -227,22 +233,25 @@ public function setState($v) {
* @param string $v
* @return void
*/
public function setNotes($v) {
public function setNotes($v)
{
$this->notes = $v;
}
/**
* Sets "dir" property from XML.
* @param PhingFile $f
* @return void
*/
public function setDir(PhingFile $f) {
public function setDir(PhingFile $f)
{
$this->dir = $f;
}

/**
* Sets the file to use for generated package.xml
*/
public function setDestFile(PhingFile $f) {
public function setDestFile(PhingFile $f)
{
$this->packageFile = $f;
}

Expand Down
5 changes: 3 additions & 2 deletions generator/pear/build-pear-package.xml
Expand Up @@ -19,8 +19,9 @@
<property name="build.src.dir" value="${build.base.dir}/${pkgname}"/>

<!-- some default properties -->
<property name="notes"><![CDATA[This is a beta release for the 1.5 branch of the Propel Generator.
See: http://propel.phpdb.org/trac/query?status=closed&milestone=1.5&resolution=fixed&order=priority for CHANGELOG.
<property name="notes"><![CDATA[
This is a beta release for the 1.5 branch of the Propel Generator.
See http://www.propelorm.org/query?status=closed&milestone=1.5+Beta+1&resolution=fixed&order=priority for CHANGELOG.
]]></property>
<property name="state" value="beta"/>

Expand Down
4 changes: 2 additions & 2 deletions generator/pear/build.properties
@@ -1,5 +1,5 @@
# In this file you can define any properties taht you want to affect
# all projects built using the propel-gen script on this system
#
# See http://propel.phpdb.org/trac/wiki/Users/Documentation/BuildProperties for a
# list of available properties.
# See http://www.propelorm.org/wiki/Documentation/1.5/BuildConfiguration
# for a list of available properties.
1 change: 0 additions & 1 deletion generator/pear/pear-propel-gen
Expand Up @@ -11,7 +11,6 @@

# (currently this is not reached)
if (test -z "$PHING_COMMAND") ; then
echo "WARNING: PHP_COMMAND environment not set. (Assuming phing on PATH)"
export PHING_COMMAND="phing"
fi

Expand Down
2 changes: 1 addition & 1 deletion runtime/lib/query/Criteria.php
Expand Up @@ -741,7 +741,7 @@ public function addJoin($left, $right, $operator = null)

/**
* Add a join with multiple conditions
* see http://propel.phpdb.org/trac/ticket/167, http://propel.phpdb.org/trac/ticket/606
* @see http://propel.phpdb.org/trac/ticket/167, http://propel.phpdb.org/trac/ticket/606
*
* Example usage:
* $c->addMultipleJoin(array(
Expand Down

0 comments on commit 05357dd

Please sign in to comment.