Hello community, here is the log from the commit of package yast2-packager checked in at Wed Sep 12 16:51:00 CEST 2007. -------- --- yast2-packager/yast2-packager.changes 2007-09-11 16:07:26.000000000 +0200 +++ /mounts/work_src_done/STABLE/yast2-packager/yast2-packager.changes 2007-09-12 16:21:23.000000000 +0200 @@ -1,0 +2,9 @@ +Wed Sep 12 16:16:08 CEST 2007 - locilka@suse.cz + +- Fixed evaluation of $short_language localization key in online + repositories. +- Adapted ag_xmlrepos to understand xml:lang="..." additionally to + lang="..." (both #299230). +- 2.15.78 + +------------------------------------------------------------------- Old: ---- yast2-packager-2.15.77.tar.bz2 New: ---- yast2-packager-2.15.78.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-packager.spec ++++++ --- /var/tmp/diff_new_pack.q25205/_old 2007-09-12 16:50:50.000000000 +0200 +++ /var/tmp/diff_new_pack.q25205/_new 2007-09-12 16:50:50.000000000 +0200 @@ -1,5 +1,5 @@ # -# spec file for package yast2-packager (Version 2.15.77) +# spec file for package yast2-packager (Version 2.15.78) # # Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine @@ -11,12 +11,12 @@ # norootforbuild Name: yast2-packager -Version: 2.15.77 +Version: 2.15.78 Release: 1 License: GPL v2 or later Group: System/YaST BuildRoot: %{_tmppath}/%{name}-%{version}-build -Source0: yast2-packager-2.15.77.tar.bz2 +Source0: yast2-packager-2.15.78.tar.bz2 prefix: /usr BuildRequires: docbook-xsl-stylesheets doxygen gcc-c++ libxcrypt-devel libxslt perl-XML-Writer sgml-skel update-desktop-files yast2-country yast2-devtools yast2-slp yast2-testsuite yast2-xml BuildRequires: yast2 >= 2.15.38 @@ -59,7 +59,7 @@ Arvin Schnell <arvin@suse.de> %prep -%setup -n yast2-packager-2.15.77 +%setup -n yast2-packager-2.15.78 %build %{prefix}/bin/y2tool y2autoconf @@ -100,6 +100,12 @@ %doc %{prefix}/share/doc/packages/yast2-packager %changelog +* Wed Sep 12 2007 - locilka@suse.cz +- Fixed evaluation of $short_language localization key in online + repositories. +- Adapted ag_xmlrepos to understand xml:lang="..." additionally to + lang="..." (both #299230). +- 2.15.78 * Tue Sep 11 2007 - locilka@suse.cz - Online repositories need to be added with unique alias (#309317). - Better error handling in checkmedia feature (#305495). ++++++ yast2-packager-2.15.77.tar.bz2 -> yast2-packager-2.15.78.tar.bz2 ++++++ diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-packager-2.15.77/agents/ag_xmlrepos new/yast2-packager-2.15.78/agents/ag_xmlrepos --- old/yast2-packager-2.15.77/agents/ag_xmlrepos 2007-08-02 14:21:09.000000000 +0200 +++ new/yast2-packager-2.15.78/agents/ag_xmlrepos 2007-09-12 15:55:53.000000000 +0200 @@ -20,7 +20,7 @@ } elsif ($variable =~ /^HASH\(/) { return [$variable]; } else { - warn "Unknown: ".$variable."\n"; + y2error ("Unknown: ".$variable); return []; } } @@ -141,7 +141,16 @@ my $variable_list = GetListFromVariable ($one_repo->{$key} || {}); foreach my $repo_keys (@{$variable_list}) { - my $lang = $repo_keys->{'lang'}->{'value'} || $default_lang; + my $lang = ""; + + if (defined $repo_keys->{'lang'}->{'value'}) { + $lang = $repo_keys->{'lang'}->{'value'}; + } elsif (defined $repo_keys->{'xml:lang'}->{'value'}) { + $lang = $repo_keys->{'xml:lang'}->{'value'}; + } else { + $lang = $default_lang; + } + $this_repo->{'localized_'.$key}->{$lang} = $repo_keys->{'value'} || ""; } diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-packager-2.15.77/src/clients/inst_productsources.ycp new/yast2-packager-2.15.78/src/clients/inst_productsources.ycp --- old/yast2-packager-2.15.77/src/clients/inst_productsources.ycp 2007-09-11 16:01:33.000000000 +0200 +++ new/yast2-packager-2.15.78/src/clients/inst_productsources.ycp 2007-09-12 15:58:34.000000000 +0200 @@ -490,6 +490,9 @@ } }); + // just for debugging purposes + y2debug ("%1", list_of_repos); + return true; } @@ -609,9 +612,15 @@ language_long = GetCurrentLang (); // fallback if no LANG variable set - if (language_long == nil) + if (language_long == nil || language_long == "") language_long = Language::language; + // de_DE.UTF-8 --> de_DE + integer dot_pos = search (language_long, "."); + if (dot_pos != nil) { + language_long = substring (language_long, 0, dot_pos); + } + if (language_long != nil) { if (size(language_long) >= 2) { language_short = substring (language_long, 0, 2); @@ -679,6 +688,7 @@ string GetLocalizedString (string current_id, list <string> possible_keys) { string ret = ""; + // try localized strings at first foreach (string possible_key, possible_keys, { string loc_key = sformat ("localized_%1", possible_key); @@ -686,20 +696,18 @@ ret = list_of_repos[current_id, loc_key, language_long]:""; break; } else if (list_of_repos[current_id, loc_key, language_short]:"" != "") { - ret = list_of_repos[current_id, loc_key, language_long]:""; + ret = list_of_repos[current_id, loc_key, language_short]:""; break; } }); if (ret != "") return ret; + // try default strings foreach (string possible_key, possible_keys, { if (list_of_repos[current_id, possible_key]:"" != "") { ret = list_of_repos[current_id, possible_key]:""; break; - } else if (list_of_repos[current_id, possible_key]:"" != "") { - ret = list_of_repos[current_id, possible_key]:""; - break; } }); diff -urN --exclude=CVS --exclude=.cvsignore --exclude=.svn --exclude=.svnignore old/yast2-packager-2.15.77/VERSION new/yast2-packager-2.15.78/VERSION --- old/yast2-packager-2.15.77/VERSION 2007-09-11 16:04:24.000000000 +0200 +++ new/yast2-packager-2.15.78/VERSION 2007-09-12 16:15:58.000000000 +0200 @@ -1 +1 @@ -2.15.77 +2.15.78 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Remember to have fun... --------------------------------------------------------------------- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org
participants (1)
-
root@Hilbert.suse.de