Mailinglist Archive: zypp-commit (223 mails)

< Previous Next >
[zypp-commit] r10684 - in /trunk/sat-solver: README examples/perl/example.pl
  • From: mlschroe@xxxxxxxxxxxxxxxx
  • Date: Tue, 29 Jul 2008 08:47:56 -0000
  • Message-id: <20080729084756.900B32E2A0@xxxxxxxxxxxxxxxx>
Author: mlschroe
Date: Tue Jul 29 10:47:56 2008
New Revision: 10684

URL: http://svn.opensuse.org/viewcvs/zypp?rev=10684&view=rev
Log:
- fix typo
- make perl code more perlish

Modified:
trunk/sat-solver/README
trunk/sat-solver/examples/perl/example.pl

Modified: trunk/sat-solver/README
URL:
http://svn.opensuse.org/viewcvs/zypp/trunk/sat-solver/README?rev=10684&r1=10683&r2=10684&view=diff
==============================================================================
--- trunk/sat-solver/README (original)
+++ trunk/sat-solver/README Tue Jul 29 10:47:56 2008
@@ -37,6 +37,6 @@
To install ruby bindings:
make install

-To createe a package
+To create a package
make srcpackage
see package/

Modified: trunk/sat-solver/examples/perl/example.pl
URL:
http://svn.opensuse.org/viewcvs/zypp/trunk/sat-solver/examples/perl/example.pl?rev=10684&r1=10683&r2=10684&view=diff
==============================================================================
--- trunk/sat-solver/examples/perl/example.pl (original)
+++ trunk/sat-solver/examples/perl/example.pl Tue Jul 29 10:47:56 2008
@@ -9,34 +9,34 @@

# Create Pool and Repository
my $pool = new satsolverx::Pool;
-$pool -> set_arch( 'i686' );
-my $repo = $pool -> create_repo('repo');
+$pool->set_arch( 'i686' );
+my $repo = $pool->create_repo('repo');

# Add Solvable to Repository
-$repo -> add_solv ("tmp/primary");
+$repo->add_solv ("tmp/primary");
# close(F) || die;

# Create Solver
-my $solver = $pool -> create_solver();
+my $solver = $pool->create_solver();

# Create dependencies to provides table
-$pool -> prepare();
+$pool->prepare();

# Create Transactions
-my $job = $pool -> create_transaction();
+my $job = $pool->create_transaction();

# Push jobs on Queue
-my $pat = $pool -> find( "pattern:default" ) || die;
-$job -> install( $pat );
+my $pat = $pool->find("pattern:default") || die;
+$job->install($pat);

-# $job -> install( "pattern:default" );
+# $job -> install("pattern:default");

# Solve the jobs
-$solver -> solve ($job);
+$solver->solve ($job);

# Print packages to install
-$a = $solver -> getInstallList();
-foreach my $c (@{$a}) {
- print "$c\n";
+$a = $solver->getInstallList();
+for my $c (@$a) {
+ print "$c\n";
}


--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages