diff options
Diffstat (limited to 'examples')
-rwxr-xr-x | examples/p5solv | 4 | ||||
-rwxr-xr-x | examples/pysolv | 4 | ||||
-rwxr-xr-x | examples/rbsolv | 6 |
3 files changed, 5 insertions, 9 deletions
diff --git a/examples/p5solv b/examples/p5solv index ac2e730..77d580a 100755 --- a/examples/p5solv +++ b/examples/p5solv @@ -627,9 +627,7 @@ while (1) { last unless @problems; for my $problem (@problems) { print "Problem $problem->{id}/".@problems.":\n"; - my $r = $problem->findproblemrule(); - my $ri = $r->info(); - print $ri->problemstr()."\n"; + print $problem->str()."\n"; my @solutions = $problem->solutions(); for my $solution (@solutions) { print " Solution $solution->{id}:\n"; diff --git a/examples/pysolv b/examples/pysolv index a658eab..fe217e1 100755 --- a/examples/pysolv +++ b/examples/pysolv @@ -768,9 +768,7 @@ while True: break for problem in problems: print "Problem %d/%d:" % (problem.id, len(problems)) - r = problem.findproblemrule() - ri = r.info() - print ri.problemstr() + print problem solutions = problem.solutions() for solution in solutions: print " Solution %d:" % solution.id diff --git a/examples/rbsolv b/examples/rbsolv index 6119190..c67a4c4 100755 --- a/examples/rbsolv +++ b/examples/rbsolv @@ -527,7 +527,7 @@ end for reposdir in reposdirs do next unless FileTest.directory?(reposdir) for reponame in Dir["#{reposdir}/*.repo"].sort do - cfg = IniFile.new(reponame) + cfg = IniFile.load(reponame) cfg.each_section do |ali| repoattr = { 'alias' => ali, 'enabled' => 0, 'priority' => 99, 'autorefresh' => 1, 'type' => 'rpm-md', 'metadata_expire' => 900} repoattr.update(cfg[ali]) @@ -641,7 +641,7 @@ while true break if problems.empty? for problem in problems puts "Problem #{problem.id}/#{problems.count}:" - puts problem.findproblemrule.info.problemstr + puts problem solutions = problem.solutions for solution in solutions puts " Solution #{solution.id}:" @@ -712,7 +712,7 @@ for cl in trans.classify(Solv::Transaction::SOLVER_TRANSACTION_SHOW_OBSOLETES | end puts "install size change: #{trans.calc_installsizechange()} K\n\n" -while true: +while true print("OK to continue (y/n)? ") STDOUT.flush yn = STDIN.gets.strip |