From 041c93ce0bc00cb6417ce2e4bdce2ed84d37f50a Mon Sep 17 00:00:00 2001
From: Aleksander Machniak <alec@alec.pl>
Date: Tue, 22 May 2012 06:31:37 -0400
Subject: [PATCH] Removed $Id$

---
 bin/exportgettext.sh |   21 +++++++++------------
 1 files changed, 9 insertions(+), 12 deletions(-)

diff --git a/bin/exportgettext.sh b/bin/exportgettext.sh
index 67fa7ad..f4a3fdb 100755
--- a/bin/exportgettext.sh
+++ b/bin/exportgettext.sh
@@ -1,7 +1,6 @@
 #!/usr/bin/env php
 <?php
 /*
-
  +-----------------------------------------------------------------------+
  | bin/exportgettext.sh                                                  |
  |                                                                       |
@@ -14,9 +13,6 @@
  +-----------------------------------------------------------------------+
  | Author: Thomas Bruederli <roundcube@gmail.com>                        |
  +-----------------------------------------------------------------------+
-
- $Id$
-
 */
 
 define('INSTALL_PATH', realpath(dirname(__FILE__) . '/..') . '/' );
@@ -30,20 +26,21 @@
 $destdir = unslashify($argv[2]);
 $layout = 'launchpad';  # or 'narro';
 $langcode_map = array(
-	'hy_AM' => 'am',
+	'hy_AM' => 'hy',
 	'ar_SA' => 'ar',
 	'az_AZ' => 'az',
 	'bg_BG' => 'bg',
 	'bs_BA' => 'bs',
 	'ca_ES' => 'ca',
-	'cs_CZ' => 'cz',
+	'cs_CZ' => 'cs',
 	'cy_GB' => 'cy',
 	'da_DK' => 'da',
 	'et_EE' => 'et',
 	'el_GR' => 'el',
 	'eu_ES' => 'eu',
+	'fa_IR' => 'fa',
 	'ga_IE' => 'ga',
-	'ka_GE' => 'ge',
+	'ka_GE' => 'ka',
 	'gl_ES' => 'gl',
 	'he_IL' => 'he',
 	'hi_IN' => 'hi',
@@ -106,7 +103,7 @@
 	}
 	else if (is_file($fn)) {
 		include($fn);
-		$texts = array_merge($texts, (array)$labels);
+		$texts = array_merge($texts, (array)$labels, (array)$messages);
 	}
 	
 	$GLOBALS['en_US'] = $texts;
@@ -175,7 +172,7 @@
 	}
 
 	include($fn);
-	$texts = $labels ? $labels : $messages;
+	$texts = array_merge($labels, $messages);
 	
 	// write header
 	$header = <<<EOF
@@ -196,7 +193,7 @@
 "Content-Transfer-Encoding: 8bit\\n"
 EOF;
 	
-	$out = sprintf($header, $srcname, $product, $is_pot ? "POT-Creation-Date" : "PO-Revision-Date", date('c'), $lang);
+	$out = sprintf($header, $srcname, $product, $is_pot ? "POT-Creation-Date" : "PO-Revision-Date", date('c'), $shortlang ? $shortlang : $lang);
 	$out .= "\n";
 	
 	$messages = array();
@@ -204,7 +201,7 @@
 		$msgid = $is_pot ? $msgstr : ($GLOBALS['en_US'][$label] ?: $label);
 		$messages[$msgid][] = $label;
 	}
-	
+
 	foreach ($messages as $msgid => $labels) {
 		$out .= "\n";
 		foreach ($labels as $label)
@@ -232,4 +229,4 @@
 	return rtrim($out);
 }
 
-?>
\ No newline at end of file
+?>

--
Gitblit v1.9.1