aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Richard Brown <rbrown@exherbo.org> 2008-08-12 19:32:02 +0100
committerAvatar Richard Brown <rbrown@exherbo.org> 2008-08-12 20:30:35 +0100
commit5359e071f7fe0e6a43764a9a6fa5160b3b2f24f6 (patch)
treefc6a404a413632eb725ecb1d8fa3e63eaf16929f
parentaacbe32dcf604490ce9211d40c0d11a6e78a4cdf (diff)
downloadpaludis-5359e071f7fe0e6a43764a9a6fa5160b3b2f24f6.tar.gz
paludis-5359e071f7fe0e6a43764a9a6fa5160b3b2f24f6.tar.xz
(ruby) Fix example parse_user_package_dep_spec
-rw-r--r--doc/api/ruby/example_action.rb2
-rw-r--r--doc/api/ruby/example_contents.rb2
-rw-r--r--doc/api/ruby/example_environment.rb2
-rw-r--r--doc/api/ruby/example_mask.rb2
-rw-r--r--doc/api/ruby/example_match_package.rb2
-rw-r--r--doc/api/ruby/example_package_id.rb2
-rw-r--r--doc/api/ruby/example_selection.rb8
7 files changed, 10 insertions, 10 deletions
diff --git a/doc/api/ruby/example_action.rb b/doc/api/ruby/example_action.rb
index 27ed221..7922344 100644
--- a/doc/api/ruby/example_action.rb
+++ b/doc/api/ruby/example_action.rb
@@ -18,7 +18,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(Generator::Matches.new(
- Paludis::parse_user_package_dep_spec("sys-apps/paludis", [])))]
+ Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])))]
# For each ID:
ids.each do | id |
diff --git a/doc/api/ruby/example_contents.rb b/doc/api/ruby/example_contents.rb
index 60f3cb5..2b48be9 100644
--- a/doc/api/ruby/example_contents.rb
+++ b/doc/api/ruby/example_contents.rb
@@ -18,7 +18,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for installed 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", [])) |
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
Filter::SupportsAction.new(InstalledAction))]
# For each ID:
diff --git a/doc/api/ruby/example_environment.rb b/doc/api/ruby/example_environment.rb
index 7ec6d25..00c98ee 100644
--- a/doc/api/ruby/example_environment.rb
+++ b/doc/api/ruby/example_environment.rb
@@ -41,7 +41,7 @@ end
# And use flags, for which we need package IDs:
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec('sys-apps/paludis', [])) |
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec('sys-apps/paludis', env, [])) |
Filter::SupportsAction.new(InstalledAction))]
if (ids.length > 0)
diff --git a/doc/api/ruby/example_mask.rb b/doc/api/ruby/example_mask.rb
index e035258..0f2f2c1 100644
--- a/doc/api/ruby/example_mask.rb
+++ b/doc/api/ruby/example_mask.rb
@@ -18,7 +18,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", [])))]
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])))]
# For each ID:
ids.each do | id |
diff --git a/doc/api/ruby/example_match_package.rb b/doc/api/ruby/example_match_package.rb
index 7ee0cd6..e0ac15d 100644
--- a/doc/api/ruby/example_match_package.rb
+++ b/doc/api/ruby/example_match_package.rb
@@ -28,7 +28,7 @@ world = env.set('world')
# For each ID:
ids.each do | id |
# Is it paludis?
- if match_package(env, parse_user_package_dep_spec('sys-apps/paludis', []), id)
+ if match_package(env, parse_user_package_dep_spec('sys-apps/paludis', env, []), id)
puts id.to_s.ljust(49) + ': paludis'
elsif match_package_in_set(env, system, id)
puts id.to_s.ljust(49) + ': system'
diff --git a/doc/api/ruby/example_package_id.rb b/doc/api/ruby/example_package_id.rb
index 01dd10c..8420911 100644
--- a/doc/api/ruby/example_package_id.rb
+++ b/doc/api/ruby/example_package_id.rb
@@ -20,7 +20,7 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# Fetch package IDs for installed 'sys-apps/paludis'
ids = env[Selection::AllVersionsSorted.new(
- Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", [])))]
+ Generator::Matches.new(Paludis::parse_user_package_dep_spec("sys-apps/paludis", env, [])))]
# For each ID:
ids.each do | id |
diff --git a/doc/api/ruby/example_selection.rb b/doc/api/ruby/example_selection.rb
index 725b26f..a718fc8 100644
--- a/doc/api/ruby/example_selection.rb
+++ b/doc/api/ruby/example_selection.rb
@@ -34,19 +34,19 @@ env = EnvironmentFactory.instance.create(ExampleCommandLine.instance.environment
# object used determines the number and ordering of results. In the
# simplest form, it takes a Generator as a parameter.
show_selection(env, Selection::AllVersionsSorted.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", []))))
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, []))))
# Generators can be passed through a Filter. The Selection optimises
# the code internally to avoid doing excess work.
show_selection(env, Selection::AllVersionsSorted.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", [])) |
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
Filter::SupportsAction.new(InstalledAction)))
# Filters can be combined. Usually Filter::NotMasked should be combined
# with Filter::SupportsAction.new(InstallAction), since installed packages
# aren't masked.
show_selection(env, Selection::AllVersionsSorted.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", [])) |
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
Filter::SupportsAction.new(InstallAction) |
Filter::NotMasked.new))
@@ -54,7 +54,7 @@ show_selection(env, Selection::AllVersionsSorted.new(
# is no metadata cache. Consider using other Selection objects if
# you only need the best matching or some arbitrary matching ID.
show_selection(env, Selection::BestVersionOnly.new(
- Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", [])) |
+ Generator::Matches.new(parse_user_package_dep_spec("sys-apps/paludis", env, [])) |
Filter::SupportsAction.new(InstallAction) |
Filter::NotMasked.new))