Hello community, here is the log from the commit of package yast2-installation for openSUSE:Factory checked in at 2012-12-07 14:53:27 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/yast2-installation (Old) and /work/SRC/openSUSE:Factory/.yast2-installation.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yast2-installation", Maintainer is "jsuch...@suse.com" Changes: -------- --- /work/SRC/openSUSE:Factory/yast2-installation/yast2-installation.changes 2012-11-05 15:07:48.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.yast2-installation.new/yast2-installation.changes 2012-12-07 14:53:29.000000000 +0100 @@ -1,0 +2,6 @@ +Tue Dec 4 16:54:56 CET 2012 - jsuch...@suse.cz + +- allow using local repositories during update (bnc#779397) +- 2.23.4 + +------------------------------------------------------------------- Old: ---- yast2-installation-2.23.3.tar.bz2 New: ---- yast2-installation-2.23.4.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ yast2-installation.spec ++++++ --- /var/tmp/diff_new_pack.K7YxYN/_old 2012-12-07 14:53:31.000000000 +0100 +++ /var/tmp/diff_new_pack.K7YxYN/_new 2012-12-07 14:53:31.000000000 +0100 @@ -17,7 +17,7 @@ Name: yast2-installation -Version: 2.23.3 +Version: 2.23.4 Release: 0 BuildRoot: %{_tmppath}/%{name}-%{version}-build ++++++ yast2-installation-2.23.3.tar.bz2 -> yast2-installation-2.23.4.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-installation-2.23.3/VERSION new/yast2-installation-2.23.4/VERSION --- old/yast2-installation-2.23.3/VERSION 2012-11-05 08:22:33.000000000 +0100 +++ new/yast2-installation-2.23.4/VERSION 2012-12-04 16:55:44.000000000 +0100 @@ -1 +1 @@ -2.23.3 +2.23.4 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-installation-2.23.3/src/clients/inst_extrasources.ycp new/yast2-installation-2.23.4/src/clients/inst_extrasources.ycp --- old/yast2-installation-2.23.3/src/clients/inst_extrasources.ycp 2012-06-25 11:05:52.000000000 +0200 +++ new/yast2-installation-2.23.4/src/clients/inst_extrasources.ycp 2012-12-04 16:53:54.000000000 +0100 @@ -48,6 +48,9 @@ import "PackagesUI"; import "Label"; +// local sources that have been attached under /mnt during upgrade +map<integer,string> local_urls = $[]; + /** * Returns list of maps of repositories to register. See bnc #381360. * @@ -149,6 +152,11 @@ { ret = add(ret, url); } + + if (Mode::update() && regexpmatch (url, "^dir:[/]+mnt[/]+")) + { + local_urls[src] = url; + } } ); @@ -157,6 +165,8 @@ y2milestone("Registered sources: %1", ret); + y2milestone("Registered local sources under /mnt: %1", local_urls); + return ret; } @@ -338,6 +348,18 @@ list <map> register_url = GetURLsToRegister (already_registered); +// fix local sources temporary attached under /mnt +if (size (local_urls) > 0) { + + foreach (integer srcid, string url, local_urls, { + string new_url = "dir:" + substring (url, find (url, "/mnt") + 4); + y2milestone ("changing temporary url '%1' to '%2'", url, new_url); + Pkg::SourceChangeUrl (srcid, new_url); + }); + Pkg::SourceSaveAll(); +} + + // any confirmed source to register? if (size (register_url) > 0) { // register (create) the sources diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/yast2-installation-2.23.3/src/clients/inst_upgrade_urls.ycp new/yast2-installation-2.23.4/src/clients/inst_upgrade_urls.ycp --- old/yast2-installation-2.23.3/src/clients/inst_upgrade_urls.ycp 2012-06-25 11:05:52.000000000 +0200 +++ new/yast2-installation-2.23.4/src/clients/inst_upgrade_urls.ycp 2012-12-04 16:54:09.000000000 +0100 @@ -219,7 +219,9 @@ list <term> items = maplist (map one_url, urls, { counter = counter + 1; - id_to_name[sformat ("ID: %1", counter)] = one_url["name"]:_("Unknown"); + // one_url already has "id" and some items might be deleted + // looking to id_to_name is done via the original key + id_to_name[one_url["id"]:sformat ("ID: %1", counter)] = one_url["name"]:_("Unknown"); return `item ( `id (counter), @@ -759,6 +761,14 @@ string repo_type = Pkg::RepositoryProbe (one_url, "/"); y2milestone ("Probed repository: %1 type: %2", one_url, repo_type); + + if ((repo_type == nil || repo_type == "NONE") && + substring (one_url, 0, 4) == "dir:") + { + one_url = "dir:/mnt" + substring (one_url, 4); + repo_type = Pkg::RepositoryProbe (one_url, "/"); + y2milestone ("Probed possible local repository again: %1 type: %2", one_url, repo_type); + } if (repo_type == nil || repo_type == "NONE") { y2error ("Cannot add repository"); -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org