From eb8812e58b5376361163d733ff40c1bc52f21090 Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 20 Mar 2012 17:49:42 +0100 Subject: [PATCH 1/2] Enable $Id$ expansion for files with the $Revision$ keyword Git supports a limited $Id$ keyword expansion. This $Id$ tag is similar to $Revision$ in SVN. We enable the $Id$ expansion only for files that use $Revision$. --- .gitattributes | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000000000..92766523d81ae --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +ext/mysqlnd/mysqlnd.h ident +ext/simplexml/simplexml.c ident +ext/iconv/php_iconv.h ident +ext/posix/posix.c ident +ext/recode/recode.c ident +ext/skeleton/create_stubs ident +ext/phar/phar/pharcommand.inc ident +ext/phar/phar.c ident +ext/sysvmsg/sysvmsg.c ident +ext/enchant/enchant.c ident +ext/reflection/php_reflection.c ident +ext/oci8/oci8.c ident +ext/dba/libinifile/inifile.c ident +ext/dba/libflatfile/flatfile.c ident +ext/dba/libcdb/cdb_make.c ident +ext/dba/libcdb/cdb.c ident +ext/filter/filter.c ident +README.input_filter ident +run-tests.php ident +sapi/nsapi/nsapi.c ident +sapi/continuity/capi.c ident +Zend/RFCs/002.txt ident +Zend/RFCs/003.txt ident From f7b10abae939412e8b5cab69cd579e071deb446b Mon Sep 17 00:00:00 2001 From: David Soria Parra Date: Tue, 20 Mar 2012 17:53:47 +0100 Subject: [PATCH 2/2] Replace $Revision$ with $Id$ in keyword expansion enable files --- README.input_filter | 2 +- Zend/RFCs/002.txt | 2 +- Zend/RFCs/003.txt | 2 +- ext/dba/libcdb/cdb.c | 2 +- ext/dba/libcdb/cdb_make.c | 2 +- ext/dba/libflatfile/flatfile.c | 2 +- ext/dba/libinifile/inifile.c | 2 +- ext/enchant/enchant.c | 2 +- ext/filter/filter.c | 2 +- ext/iconv/php_iconv.h | 2 +- ext/mysqlnd/mysqlnd.h | 2 +- ext/oci8/oci8.c | 2 +- ext/phar/phar.c | 2 +- ext/phar/phar/pharcommand.inc | 2 +- ext/posix/posix.c | 2 +- ext/recode/recode.c | 2 +- ext/reflection/php_reflection.c | 4 ++-- ext/simplexml/simplexml.c | 2 +- ext/skeleton/create_stubs | 2 +- ext/sysvmsg/sysvmsg.c | 2 +- run-tests.php | 2 +- sapi/continuity/capi.c | 2 +- sapi/nsapi/nsapi.c | 2 +- 23 files changed, 24 insertions(+), 24 deletions(-) diff --git a/README.input_filter b/README.input_filter index 8fb8244bd8239..488ca82a7b156 100644 --- a/README.input_filter +++ b/README.input_filter @@ -88,7 +88,7 @@ PHP_MINFO_FUNCTION(my_input_filter) { php_info_print_table_start(); php_info_print_table_row( 2, "My Input Filter Support", "enabled" ); - php_info_print_table_row( 2, "Revision", "$Revision$"); + php_info_print_table_row( 2, "Revision", "$Id$"); php_info_print_table_end(); } diff --git a/Zend/RFCs/002.txt b/Zend/RFCs/002.txt index 4b52696bbc1f6..7d7cb885d85b5 100644 --- a/Zend/RFCs/002.txt +++ b/Zend/RFCs/002.txt @@ -1,5 +1,5 @@ Title: Zend 2.0 Namespaces -Version: $Revision$ +Version: $Id$ Status: declined Maintainer: Stig S. Bakken Created: 2001-09-08 diff --git a/Zend/RFCs/003.txt b/Zend/RFCs/003.txt index aa90691b1964a..30fb4cec4912f 100644 --- a/Zend/RFCs/003.txt +++ b/Zend/RFCs/003.txt @@ -1,5 +1,5 @@ Title: Loose type requirements for functions -Version: $Revision$ +Version: $Id$ Status: draft Maintainer: Brian Moon Created: 2001-09-17 diff --git a/ext/dba/libcdb/cdb.c b/ext/dba/libcdb/cdb.c index a4a04474cc5fc..5c26b4fd9f2af 100644 --- a/ext/dba/libcdb/cdb.c +++ b/ext/dba/libcdb/cdb.c @@ -189,6 +189,6 @@ int cdb_find(struct cdb *c, char *key, unsigned int len TSRMLS_DC) /* {{{ cdb_version */ char *cdb_version() { - return "0.75, $Revision$"; + return "0.75, $Id$"; } /* }}} */ diff --git a/ext/dba/libcdb/cdb_make.c b/ext/dba/libcdb/cdb_make.c index e6e7f6f557309..600b8dd0f9187 100644 --- a/ext/dba/libcdb/cdb_make.c +++ b/ext/dba/libcdb/cdb_make.c @@ -240,5 +240,5 @@ int cdb_make_finish(struct cdb_make *c TSRMLS_DC) /* {{{ cdb_make_version */ char *cdb_make_version() { - return "0.75, $Revision$"; + return "0.75, $Id$"; } diff --git a/ext/dba/libflatfile/flatfile.c b/ext/dba/libflatfile/flatfile.c index 1b66d0814c50f..081af745f946e 100644 --- a/ext/dba/libflatfile/flatfile.c +++ b/ext/dba/libflatfile/flatfile.c @@ -307,7 +307,7 @@ datum flatfile_nextkey(flatfile *dba TSRMLS_DC) { /* {{{ flatfile_version */ char *flatfile_version() { - return "1.0, $Revision$"; + return "1.0, $Id$"; } /* }}} */ diff --git a/ext/dba/libinifile/inifile.c b/ext/dba/libinifile/inifile.c index b40dd8c0ed7e7..f7157ed0fee89 100644 --- a/ext/dba/libinifile/inifile.c +++ b/ext/dba/libinifile/inifile.c @@ -43,7 +43,7 @@ /* {{{ inifile_version */ char *inifile_version() { - return "1.0, $Revision$"; + return "1.0, $Id$"; } /* }}} */ diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c index 7b302e0dfdb96..0126d9ef4ed28 100755 --- a/ext/enchant/enchant.c +++ b/ext/enchant/enchant.c @@ -326,7 +326,7 @@ PHP_MINFO_FUNCTION(enchant) #elif defined(HAVE_ENCHANT_BROKER_SET_PARAM) php_info_print_table_row(2, "Libenchant Version", "1.5.0 or later"); #endif - php_info_print_table_row(2, "Revision", "$Revision$"); + php_info_print_table_row(2, "Revision", "$Id$"); php_info_print_table_end(); php_info_print_table_start(); diff --git a/ext/filter/filter.c b/ext/filter/filter.c index 9247615da55b7..2b8c730d7dfaa 100644 --- a/ext/filter/filter.c +++ b/ext/filter/filter.c @@ -318,7 +318,7 @@ PHP_MINFO_FUNCTION(filter) { php_info_print_table_start(); php_info_print_table_row( 2, "Input Validation and Filtering", "enabled" ); - php_info_print_table_row( 2, "Revision", "$Revision$"); + php_info_print_table_row( 2, "Revision", "$Id$"); php_info_print_table_end(); DISPLAY_INI_ENTRIES(); diff --git a/ext/iconv/php_iconv.h b/ext/iconv/php_iconv.h index 42210d4a249d8..8024fda0803df 100644 --- a/ext/iconv/php_iconv.h +++ b/ext/iconv/php_iconv.h @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Revision$ */ +/* $Id$ */ #ifndef PHP_ICONV_H #define PHP_ICONV_H diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h index 63f8551a79e9e..65fe78e70ce53 100644 --- a/ext/mysqlnd/mysqlnd.h +++ b/ext/mysqlnd/mysqlnd.h @@ -22,7 +22,7 @@ #ifndef MYSQLND_H #define MYSQLND_H -#define MYSQLND_VERSION "mysqlnd 5.0.8-dev - 20102224 - $Revision$" +#define MYSQLND_VERSION "mysqlnd 5.0.8-dev - 20102224 - $Id$" #define MYSQLND_VERSION_ID 50008 /* This forces inlining of some accessor functions */ diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c index f323d3e6726e1..bf2eaf558b050 100644 --- a/ext/oci8/oci8.c +++ b/ext/oci8/oci8.c @@ -1341,7 +1341,7 @@ PHP_MINFO_FUNCTION(oci) php_info_print_table_start(); php_info_print_table_row(2, "OCI8 Support", "enabled"); php_info_print_table_row(2, "Version", PHP_OCI8_VERSION); - php_info_print_table_row(2, "Revision", "$Revision$"); + php_info_print_table_row(2, "Revision", "$Id$"); snprintf(buf, sizeof(buf), "%ld", OCI_G(num_persistent)); php_info_print_table_row(2, "Active Persistent Connections", buf); diff --git a/ext/phar/phar.c b/ext/phar/phar.c index 4ab2b863765e4..d8eaad1a2452a 100644 --- a/ext/phar/phar.c +++ b/ext/phar/phar.c @@ -3669,7 +3669,7 @@ PHP_MINFO_FUNCTION(phar) /* {{{ */ php_info_print_table_header(2, "Phar: PHP Archive support", "enabled"); php_info_print_table_row(2, "Phar EXT version", PHP_PHAR_VERSION); php_info_print_table_row(2, "Phar API version", PHP_PHAR_API_VERSION); - php_info_print_table_row(2, "SVN revision", "$Revision$"); + php_info_print_table_row(2, "SVN revision", "$Id$"); php_info_print_table_row(2, "Phar-based phar archives", "enabled"); php_info_print_table_row(2, "Tar-based phar archives", "enabled"); php_info_print_table_row(2, "ZIP-based phar archives", "enabled"); diff --git a/ext/phar/phar/pharcommand.inc b/ext/phar/phar/pharcommand.inc index 9a111b8d83b18..9e968694c3f62 100755 --- a/ext/phar/phar/pharcommand.inc +++ b/ext/phar/phar/pharcommand.inc @@ -1566,7 +1566,7 @@ class PharCommand extends CLICommand $use_ext = extension_loaded('phar'); $version = array( 'PHP Version' => phpversion(), - 'phar.phar version' => '$Revision$', + 'phar.phar version' => '$Id$', 'Phar EXT version' => $use_ext ? phpversion('phar') : 'Not available', 'Phar API version' => Phar::apiVersion(), 'Phar-based phar archives' => true, diff --git a/ext/posix/posix.c b/ext/posix/posix.c index ab19eb2f64de0..c00b7465003bf 100644 --- a/ext/posix/posix.c +++ b/ext/posix/posix.c @@ -310,7 +310,7 @@ const zend_function_entry posix_functions[] = { static PHP_MINFO_FUNCTION(posix) { php_info_print_table_start(); - php_info_print_table_row(2, "Revision", "$Revision$"); + php_info_print_table_row(2, "Revision", "$Id$"); php_info_print_table_end(); } /* }}} */ diff --git a/ext/recode/recode.c b/ext/recode/recode.c index fdbc4d0d5fe8a..e17429b238eb2 100644 --- a/ext/recode/recode.c +++ b/ext/recode/recode.c @@ -135,7 +135,7 @@ PHP_MINFO_FUNCTION(recode) { php_info_print_table_start(); php_info_print_table_row(2, "Recode Support", "enabled"); - php_info_print_table_row(2, "Revision", "$Revision$"); + php_info_print_table_row(2, "Revision", "$Id$"); php_info_print_table_end(); } diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c index 94cc05ee584bb..522fef1e5100f 100644 --- a/ext/reflection/php_reflection.c +++ b/ext/reflection/php_reflection.c @@ -5552,7 +5552,7 @@ PHP_MINFO_FUNCTION(reflection) /* {{{ */ php_info_print_table_start(); php_info_print_table_header(2, "Reflection", "enabled"); - php_info_print_table_row(2, "Version", "$Revision$"); + php_info_print_table_row(2, "Version", "$Id$"); php_info_print_table_end(); } /* }}} */ @@ -5566,7 +5566,7 @@ zend_module_entry reflection_module_entry = { /* {{{ */ NULL, NULL, PHP_MINFO(reflection), - "$Revision$", + "$Id$", STANDARD_MODULE_PROPERTIES }; /* }}} */ diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index b6d94d02357b3..a379111021e24 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -2608,7 +2608,7 @@ PHP_MINFO_FUNCTION(simplexml) { php_info_print_table_start(); php_info_print_table_header(2, "Simplexml support", "enabled"); - php_info_print_table_row(2, "Revision", "$Revision$"); + php_info_print_table_row(2, "Revision", "$Id$"); php_info_print_table_row(2, "Schema support", #ifdef LIBXML_SCHEMAS_ENABLED "enabled"); diff --git a/ext/skeleton/create_stubs b/ext/skeleton/create_stubs index 0a5f28607e274..f9f39b1795f7e 100755 --- a/ext/skeleton/create_stubs +++ b/ext/skeleton/create_stubs @@ -67,7 +67,7 @@ BEGIN { xmlhead = "\n" \ - "\n" \ + "\n" \ " \n" \ " functions\n" \ " \n\n" \ diff --git a/ext/sysvmsg/sysvmsg.c b/ext/sysvmsg/sysvmsg.c index 1bc8b63d51074..bf99fb053e35d 100644 --- a/ext/sysvmsg/sysvmsg.c +++ b/ext/sysvmsg/sysvmsg.c @@ -145,7 +145,7 @@ PHP_MINFO_FUNCTION(sysvmsg) { php_info_print_table_start(); php_info_print_table_row(2, "sysvmsg support", "enabled"); - php_info_print_table_row(2, "Revision", "$Revision$"); + php_info_print_table_row(2, "Revision", "$Id$"); php_info_print_table_end(); } /* }}} */ diff --git a/run-tests.php b/run-tests.php index 4549659ce21cc..38048706060d5 100755 --- a/run-tests.php +++ b/run-tests.php @@ -666,7 +666,7 @@ function save_or_mail_results() $html_output = is_resource($html_file); break; case '--version': - echo '$Revision$' . "\n"; + echo '$Id$' . "\n"; exit(1); default: diff --git a/sapi/continuity/capi.c b/sapi/continuity/capi.c index 860a760b36fa1..cdf7283bd8a84 100644 --- a/sapi/continuity/capi.c +++ b/sapi/continuity/capi.c @@ -110,7 +110,7 @@ PHP_MSHUTDOWN_FUNCTION(continuity) PHP_MINFO_FUNCTION(continuity) { php_info_print_table_start(); - php_info_print_table_row(2, "Continuity Module Revision", "$Revision$"); + php_info_print_table_row(2, "Continuity Module Revision", "$Id$"); php_info_print_table_row(2, "Server Version", conFget_build()); #ifdef CONTINUITY_CDPEXT php_info_print_table_row(2,"CDP Extensions", "enabled"); diff --git a/sapi/nsapi/nsapi.c b/sapi/nsapi/nsapi.c index 21089af6f9bc6..202bf54bcf847 100644 --- a/sapi/nsapi/nsapi.c +++ b/sapi/nsapi/nsapi.c @@ -312,7 +312,7 @@ PHP_MSHUTDOWN_FUNCTION(nsapi) PHP_MINFO_FUNCTION(nsapi) { php_info_print_table_start(); - php_info_print_table_row(2, "NSAPI Module Revision", "$Revision$"); + php_info_print_table_row(2, "NSAPI Module Revision", "$Id$"); php_info_print_table_row(2, "Server Software", system_version()); php_info_print_table_row(2, "Sub-requests with nsapi_virtual()", (nsapi_servact_service)?((zend_ini_long("zlib.output_compression", sizeof("zlib.output_compression"), 0))?"not supported with zlib.output_compression":"enabled"):"not supported on this platform" );