Merge branch 'pearpkg'
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@717 b3834d28-1941-0410-a4f8-b48e95affb8f
This commit is contained in:
commit
05832245e2
7 changed files with 189 additions and 11 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
||||||
dist/
|
dist/
|
||||||
build.properties
|
build.properties
|
||||||
|
package.xml
|
||||||
|
|
159
build.xml
159
build.xml
|
@ -10,12 +10,26 @@
|
||||||
|
|
||||||
<property name="version-m" value="0.97" />
|
<property name="version-m" value="0.97" />
|
||||||
<property name="version" value="0.97.0" />
|
<property name="version" value="0.97.0" />
|
||||||
|
<property name="stability" value="beta" />
|
||||||
|
<property name="releasenotes" value="- Many SQL optimizations
|
||||||
|
- SemanticScuttle shows bookmarks 4 times faster now
|
||||||
|
- New config option to skip 'SET NAMES UTF8' call: $dbneedssetnames
|
||||||
|
- Do not highlight admin bookmarks when $enableAdminColors is disabled
|
||||||
|
- Add russian translation
|
||||||
|
- Make HTML export follow the specifications a bit better
|
||||||
|
- Fix bug #2953732: faulty error message for duplicate bookmarks
|
||||||
|
- Fix bug #2960663: do not send content-type headers twice for ajax/api scripts
|
||||||
|
- Fix bug #2976593: fr_FR locale is vietnamese
|
||||||
|
" />
|
||||||
<property name="zipfile" value="${phing.project.name}-${version}.zip" />
|
<property name="zipfile" value="${phing.project.name}-${version}.zip" />
|
||||||
|
<property name="pkgfile" value="${phing.project.name}-${version}.tgz" />
|
||||||
<property name="distfile" value="dist/${zipfile}" />
|
<property name="distfile" value="dist/${zipfile}" />
|
||||||
<property name="sfproject" value="SemanticScuttle" />
|
<property name="sfproject" value="SemanticScuttle" />
|
||||||
<property name="sffilepath" value="s/se/semanticscuttle/" />
|
<property name="sffilepath" value="s/se/semanticscuttle/" />
|
||||||
<property name="svnpath" value="https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/" />
|
<property name="svnpath" value="https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/" />
|
||||||
|
|
||||||
|
<taskdef classname="phing.tasks.ext.d51PearPkg2Task" name="d51pearpkg2" />
|
||||||
|
|
||||||
<target name="zip" depends="check"
|
<target name="zip" depends="check"
|
||||||
description="Create zip file for release"
|
description="Create zip file for release"
|
||||||
>
|
>
|
||||||
|
@ -48,7 +62,150 @@
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<target name="release" depends="check,zip,deploy-sf,svntag"
|
<target name="package" depends="check"
|
||||||
|
description="Creates the pear package"
|
||||||
|
>
|
||||||
|
<!-- fixme: create package.xml with d51pearpkg2 -->
|
||||||
|
<d51pearpkg2 dir="." baseinstalldir="/">
|
||||||
|
<name>SemanticScuttle</name>
|
||||||
|
<summary>A social bookmarking tool</summary>
|
||||||
|
<description>
|
||||||
|
A social bookmarking tool experimenting with new features
|
||||||
|
like structured tags or collaborative descriptions of tags.
|
||||||
|
</description>
|
||||||
|
<channel>__uri</channel>
|
||||||
|
|
||||||
|
<lead user="cweiske" name="Christian Weiske" email="cweiske@cweiske.de" />
|
||||||
|
<license>GPL</license>
|
||||||
|
|
||||||
|
<version release="${version}" api="${version}" />
|
||||||
|
<stability release="${stability}" api="${stability}" />
|
||||||
|
|
||||||
|
<notes>${releasenotes}</notes>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<php minimum_version="5.2.0" />
|
||||||
|
<pear minimum_version="1.8.1" />
|
||||||
|
|
||||||
|
<package name="HTML_QuickForm2"
|
||||||
|
channel="pear.php.net"
|
||||||
|
minimum_version="0.4.0"
|
||||||
|
/>
|
||||||
|
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
<!-- map directory (key) to role -->
|
||||||
|
<dirroles key="www">www</dirroles>
|
||||||
|
<dirroles key="data">data</dirroles>
|
||||||
|
<dirroles key="doc">doc</dirroles>
|
||||||
|
<dirroles key="src">php</dirroles>
|
||||||
|
<dirroles key="tests">test</dirroles>
|
||||||
|
|
||||||
|
<!-- do not add the following files to the package.
|
||||||
|
copied from excludes above -->
|
||||||
|
<ignore>**/.gitignore</ignore>
|
||||||
|
<ignore>**/.svn</ignore>
|
||||||
|
<ignore>build*</ignore>
|
||||||
|
<ignore>data/config.php</ignore>
|
||||||
|
<ignore>data/locales/messages.po</ignore>
|
||||||
|
<ignore>data/locales/*/LC_MESSAGES/messages.po</ignore>
|
||||||
|
<ignore>dist/**</ignore>
|
||||||
|
<ignore>doc/developers/**</ignore>
|
||||||
|
<ignore>scripts/**</ignore>
|
||||||
|
<ignore>src/php-gettext/examples/**</ignore>
|
||||||
|
<ignore>src/php-gettext/bin/**</ignore>
|
||||||
|
<ignore>*.tgz</ignore>
|
||||||
|
|
||||||
|
<replacement
|
||||||
|
path="src/SemanticScuttle/header.php"
|
||||||
|
type="pear-config"
|
||||||
|
from="@data_dir@" to="data_dir"
|
||||||
|
/>
|
||||||
|
<replacement
|
||||||
|
path="www/www-header.php"
|
||||||
|
type="pear-config"
|
||||||
|
from="@data_dir@" to="data_dir"
|
||||||
|
/>
|
||||||
|
<replacement
|
||||||
|
path="tests/prepare.php"
|
||||||
|
type="pear-config"
|
||||||
|
from="@data_dir@" to="data_dir"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<changelog version="0.97" date="2010-06-09" license="GPL">
|
||||||
|
- Many SQL optimizations - SemanticScuttle shows bookmarks 4 times faster now
|
||||||
|
- New config option to skip "SET NAMES UTF8" call: $dbneedssetnames
|
||||||
|
- Do not highlight admin bookmarks when $enableAdminColors is disabled
|
||||||
|
- Add russian translation
|
||||||
|
- Make HTML export follow the specifications a bit better
|
||||||
|
- Fix bug #2953732: faulty error message for duplicate bookmarks
|
||||||
|
- Fix bug #2960663: do not send content-type headers twice for ajax/api scripts
|
||||||
|
- Fix bug #2976593: fr_FR locale is vietnamese
|
||||||
|
</changelog>
|
||||||
|
|
||||||
|
<!-- <dirroles key="bin">script</dirroles> -->
|
||||||
|
<!-- <replacement path="bin/doctrine" type="pear-config" from="@php_bin@" to="php_bin" /> -->
|
||||||
|
<!-- <release>
|
||||||
|
<install as="doctrine" name="bin/doctrine" />
|
||||||
|
-->
|
||||||
|
</d51pearpkg2>
|
||||||
|
|
||||||
|
<!-- time to fix the package.xml file since the task does not
|
||||||
|
allow everything we need:
|
||||||
|
- strip the base directory names like src, data and www
|
||||||
|
- remove that dumb baseinstalldir from files
|
||||||
|
- md5sums are generated automatically when packaging
|
||||||
|
-->
|
||||||
|
<!-- yes, we need to generate a 2nd file and move it back -->
|
||||||
|
<copy file="package.xml" tofile="package2.xml" overwrite="true">
|
||||||
|
<filterchain>
|
||||||
|
<replaceregexp>
|
||||||
|
<!-- remove md5sums -->
|
||||||
|
<regexp
|
||||||
|
pattern="md5sum="[a-z0-9]{32}" "
|
||||||
|
replace=""
|
||||||
|
/>
|
||||||
|
<!-- remove baseinstalldir for files -->
|
||||||
|
<regexp
|
||||||
|
pattern="<file baseinstalldir="/""
|
||||||
|
replace="<file"
|
||||||
|
/>
|
||||||
|
<!-- install-as for different directories -->
|
||||||
|
<regexp
|
||||||
|
pattern="(<file name="data/(.+?)")"
|
||||||
|
replace="\1 install-as="\2""
|
||||||
|
/>
|
||||||
|
<regexp
|
||||||
|
pattern="(<file name="doc/(.+?)")"
|
||||||
|
replace="\1 install-as="\2""
|
||||||
|
/>
|
||||||
|
<regexp
|
||||||
|
pattern="(<file name="tests/(.+?)")"
|
||||||
|
replace="\1 install-as="\2""
|
||||||
|
/>
|
||||||
|
<regexp
|
||||||
|
pattern="(<file name="www/(.+?)")"
|
||||||
|
replace="\1 install-as="SemanticScuttle/\2""
|
||||||
|
/>
|
||||||
|
<regexp
|
||||||
|
pattern="(<file name="src/(.+?)")"
|
||||||
|
replace="\1 install-as="\2""
|
||||||
|
/>
|
||||||
|
</replaceregexp>
|
||||||
|
</filterchain>
|
||||||
|
</copy>
|
||||||
|
<move file="package2.xml" tofile="package.xml" overwrite="true" />
|
||||||
|
|
||||||
|
<!-- package up -->
|
||||||
|
<exec command="pear package" passthru="true" />
|
||||||
|
<move file="${pkgfile}" todir="dist/pear/" />
|
||||||
|
|
||||||
|
<delete file="package.xml" failonerror="true" />
|
||||||
|
</target>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<target name="release" depends="check,zip,package,deploy-sf,svntag"
|
||||||
description="Release the version on sourceforge"
|
description="Release the version on sourceforge"
|
||||||
>
|
>
|
||||||
<!-- meta-target -->
|
<!-- meta-target -->
|
||||||
|
|
|
@ -4,8 +4,8 @@ How to release a new version of SemanticScuttle
|
||||||
0. Run unit tests and verify that all of them pass
|
0. Run unit tests and verify that all of them pass
|
||||||
1. Update doc/ChangeLog
|
1. Update doc/ChangeLog
|
||||||
2. Update doc/UPGRADE.txt
|
2. Update doc/UPGRADE.txt
|
||||||
3. Update version in data/templates/about.tpl.php
|
3. Update version in data/templates/about.tpl.php,
|
||||||
and build.xml
|
build.xml and doc/README.txt
|
||||||
4. Create a release zip file via the build script:
|
4. Create a release zip file via the build script:
|
||||||
Just type "phing".
|
Just type "phing".
|
||||||
5. Make a test installation from your zip file with a fresh
|
5. Make a test installation from your zip file with a fresh
|
||||||
|
|
|
@ -14,9 +14,21 @@
|
||||||
* @license GPL http://www.gnu.org/licenses/gpl.html
|
* @license GPL http://www.gnu.org/licenses/gpl.html
|
||||||
* @link http://sourceforge.net/projects/semanticscuttle
|
* @link http://sourceforge.net/projects/semanticscuttle
|
||||||
*/
|
*/
|
||||||
if (!file_exists(dirname(__FILE__) .'/../../data/config.php')) {
|
|
||||||
|
if ('@data_dir@' == '@' . 'data_dir@') {
|
||||||
|
//non pear-install
|
||||||
|
$datadir = dirname(__FILE__) . '/../../data/';
|
||||||
|
} else {
|
||||||
|
//pear installation; files are in include path
|
||||||
|
$datadir = '@data_dir@/SemanticScuttle/';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!file_exists($datadir . '/config.php')) {
|
||||||
header('HTTP/1.0 500 Internal Server Error');
|
header('HTTP/1.0 500 Internal Server Error');
|
||||||
die('Please copy "config.php.dist" to "config.php" in data/ folder.');
|
die(
|
||||||
|
'Please copy "config.php.dist" to "config.php" in data/ folder.'
|
||||||
|
. "\n"
|
||||||
|
);
|
||||||
}
|
}
|
||||||
set_include_path(
|
set_include_path(
|
||||||
get_include_path() . PATH_SEPARATOR
|
get_include_path() . PATH_SEPARATOR
|
||||||
|
@ -24,7 +36,6 @@ set_include_path(
|
||||||
);
|
);
|
||||||
|
|
||||||
// 1 // First requirements part (before debug management)
|
// 1 // First requirements part (before debug management)
|
||||||
$datadir = dirname(__FILE__) . '/../../data/';
|
|
||||||
require_once $datadir . '/config.default.php';
|
require_once $datadir . '/config.default.php';
|
||||||
require_once $datadir . '/config.php';
|
require_once $datadir . '/config.php';
|
||||||
|
|
||||||
|
|
|
@ -54,9 +54,6 @@ class TagsCacheTest extends PHPUnit_Framework_TestCase
|
||||||
|
|
||||||
protected function setUp()
|
protected function setUp()
|
||||||
{
|
{
|
||||||
global $dbhost, $dbuser, $dbpass, $dbname, $dbport, $dbpersist, $dbtype, $tableprefix, $TEMPLATES_DIR, $debugMode;
|
|
||||||
require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php';
|
|
||||||
|
|
||||||
$this->us =SemanticScuttle_Service_Factory::get('User');
|
$this->us =SemanticScuttle_Service_Factory::get('User');
|
||||||
$this->bs =SemanticScuttle_Service_Factory::get('Bookmark');
|
$this->bs =SemanticScuttle_Service_Factory::get('Bookmark');
|
||||||
$this->bs->deleteAll();
|
$this->bs->deleteAll();
|
||||||
|
|
|
@ -19,7 +19,13 @@
|
||||||
$_SERVER['HTTP_HOST'] = 'http://localhost/';
|
$_SERVER['HTTP_HOST'] = 'http://localhost/';
|
||||||
define('UNIT_TEST_MODE', true);
|
define('UNIT_TEST_MODE', true);
|
||||||
|
|
||||||
|
if ('@data_dir@' == '@' . 'data_dir@') {
|
||||||
|
//non pear-install
|
||||||
require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php';
|
require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php';
|
||||||
|
} else {
|
||||||
|
//pear installation; files are in include path
|
||||||
|
require_once 'SemanticScuttle/header.php';
|
||||||
|
}
|
||||||
require_once dirname(__FILE__) . '/TestBase.php';
|
require_once dirname(__FILE__) . '/TestBase.php';
|
||||||
require_once dirname(__FILE__) . '/TestBaseApi.php';
|
require_once dirname(__FILE__) . '/TestBaseApi.php';
|
||||||
|
|
||||||
|
|
|
@ -15,5 +15,11 @@
|
||||||
* @license GPL http://www.gnu.org/licenses/gpl.html
|
* @license GPL http://www.gnu.org/licenses/gpl.html
|
||||||
* @link http://sourceforge.net/projects/semanticscuttle
|
* @link http://sourceforge.net/projects/semanticscuttle
|
||||||
*/
|
*/
|
||||||
|
if ('@data_dir@' == '@' . 'data_dir@') {
|
||||||
|
//non pear-install
|
||||||
require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php';
|
require_once dirname(__FILE__) . '/../src/SemanticScuttle/header.php';
|
||||||
|
} else {
|
||||||
|
//pear installation; files are in include path
|
||||||
|
require_once 'SemanticScuttle/header.php';
|
||||||
|
}
|
||||||
?>
|
?>
|
Loading…
Reference in a new issue