autoproj 2.12.1 → 2.15.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (133) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/lint.yml +25 -0
  3. data/.github/workflows/test.yml +30 -0
  4. data/.rubocop.yml +79 -91
  5. data/.rubocop_todo.yml +1473 -0
  6. data/Gemfile +9 -9
  7. data/Rakefile +24 -24
  8. data/autoproj.gemspec +24 -22
  9. data/bin/alocate +4 -4
  10. data/bin/alog +6 -7
  11. data/bin/amake +4 -4
  12. data/bin/aup +4 -4
  13. data/bin/autoproj +3 -3
  14. data/bin/autoproj_bootstrap +225 -200
  15. data/bin/autoproj_bootstrap.in +7 -8
  16. data/bin/autoproj_install +224 -199
  17. data/bin/autoproj_install.in +6 -7
  18. data/lib/autoproj/aruba_minitest.rb +6 -11
  19. data/lib/autoproj/autobuild.rb +9 -6
  20. data/lib/autoproj/autobuild_extensions/archive_importer.rb +10 -11
  21. data/lib/autoproj/autobuild_extensions/dsl.rb +66 -36
  22. data/lib/autoproj/autobuild_extensions/git.rb +27 -26
  23. data/lib/autoproj/autobuild_extensions/package.rb +23 -22
  24. data/lib/autoproj/autobuild_extensions/python.rb +18 -0
  25. data/lib/autoproj/autobuild_extensions/svn.rb +1 -2
  26. data/lib/autoproj/base.rb +1 -1
  27. data/lib/autoproj/bash_completion.rb +5 -6
  28. data/lib/autoproj/build_option.rb +22 -24
  29. data/lib/autoproj/cli/base.rb +26 -26
  30. data/lib/autoproj/cli/bootstrap.rb +14 -16
  31. data/lib/autoproj/cli/build.rb +10 -7
  32. data/lib/autoproj/cli/cache.rb +11 -11
  33. data/lib/autoproj/cli/clean.rb +10 -10
  34. data/lib/autoproj/cli/commit.rb +7 -8
  35. data/lib/autoproj/cli/doc.rb +2 -2
  36. data/lib/autoproj/cli/envsh.rb +1 -2
  37. data/lib/autoproj/cli/exec.rb +60 -20
  38. data/lib/autoproj/cli/inspection_tool.rb +13 -7
  39. data/lib/autoproj/cli/locate.rb +30 -41
  40. data/lib/autoproj/cli/log.rb +7 -7
  41. data/lib/autoproj/cli/main.rb +217 -205
  42. data/lib/autoproj/cli/main_doc.rb +22 -21
  43. data/lib/autoproj/cli/main_global.rb +44 -19
  44. data/lib/autoproj/cli/main_plugin.rb +18 -18
  45. data/lib/autoproj/cli/main_test.rb +28 -27
  46. data/lib/autoproj/cli/manifest.rb +7 -7
  47. data/lib/autoproj/cli/osdeps.rb +12 -11
  48. data/lib/autoproj/cli/patcher.rb +2 -3
  49. data/lib/autoproj/cli/query.rb +17 -18
  50. data/lib/autoproj/cli/reconfigure.rb +1 -2
  51. data/lib/autoproj/cli/reset.rb +9 -12
  52. data/lib/autoproj/cli/show.rb +38 -39
  53. data/lib/autoproj/cli/status.rb +56 -44
  54. data/lib/autoproj/cli/switch_config.rb +5 -6
  55. data/lib/autoproj/cli/tag.rb +12 -11
  56. data/lib/autoproj/cli/test.rb +7 -7
  57. data/lib/autoproj/cli/update.rb +97 -43
  58. data/lib/autoproj/cli/utility.rb +14 -12
  59. data/lib/autoproj/cli/version.rb +42 -40
  60. data/lib/autoproj/cli/versions.rb +14 -15
  61. data/lib/autoproj/cli/watch.rb +33 -37
  62. data/lib/autoproj/cli/which.rb +16 -20
  63. data/lib/autoproj/cli.rb +4 -2
  64. data/lib/autoproj/configuration.rb +78 -86
  65. data/lib/autoproj/default.osdeps +29 -3
  66. data/lib/autoproj/environment.rb +42 -23
  67. data/lib/autoproj/exceptions.rb +9 -3
  68. data/lib/autoproj/find_workspace.rb +20 -25
  69. data/lib/autoproj/git_server_configuration.rb +40 -44
  70. data/lib/autoproj/gitorious.rb +1 -1
  71. data/lib/autoproj/installation_manifest.rb +64 -29
  72. data/lib/autoproj/local_package_set.rb +13 -11
  73. data/lib/autoproj/manifest.rb +139 -132
  74. data/lib/autoproj/metapackage.rb +2 -6
  75. data/lib/autoproj/ops/atomic_write.rb +7 -6
  76. data/lib/autoproj/ops/build.rb +4 -6
  77. data/lib/autoproj/ops/cache.rb +41 -43
  78. data/lib/autoproj/ops/cached_env.rb +5 -4
  79. data/lib/autoproj/ops/configuration.rb +519 -507
  80. data/lib/autoproj/ops/import.rb +88 -63
  81. data/lib/autoproj/ops/install.rb +218 -192
  82. data/lib/autoproj/ops/loader.rb +77 -76
  83. data/lib/autoproj/ops/main_config_switcher.rb +36 -45
  84. data/lib/autoproj/ops/phase_reporting.rb +4 -4
  85. data/lib/autoproj/ops/snapshot.rb +250 -247
  86. data/lib/autoproj/ops/tools.rb +76 -78
  87. data/lib/autoproj/ops/watch.rb +6 -6
  88. data/lib/autoproj/ops/which.rb +17 -14
  89. data/lib/autoproj/options.rb +13 -2
  90. data/lib/autoproj/os_package_installer.rb +102 -92
  91. data/lib/autoproj/os_package_query.rb +7 -13
  92. data/lib/autoproj/os_package_resolver.rb +189 -140
  93. data/lib/autoproj/os_repository_installer.rb +4 -4
  94. data/lib/autoproj/os_repository_resolver.rb +8 -6
  95. data/lib/autoproj/package_definition.rb +12 -13
  96. data/lib/autoproj/package_managers/apt_dpkg_manager.rb +19 -11
  97. data/lib/autoproj/package_managers/bundler_manager.rb +186 -129
  98. data/lib/autoproj/package_managers/debian_version.rb +25 -21
  99. data/lib/autoproj/package_managers/emerge_manager.rb +2 -3
  100. data/lib/autoproj/package_managers/gem_manager.rb +68 -77
  101. data/lib/autoproj/package_managers/homebrew_manager.rb +3 -4
  102. data/lib/autoproj/package_managers/manager.rb +8 -3
  103. data/lib/autoproj/package_managers/pacman_manager.rb +2 -3
  104. data/lib/autoproj/package_managers/pip_manager.rb +30 -28
  105. data/lib/autoproj/package_managers/pkg_manager.rb +3 -4
  106. data/lib/autoproj/package_managers/port_manager.rb +2 -3
  107. data/lib/autoproj/package_managers/shell_script_manager.rb +47 -25
  108. data/lib/autoproj/package_managers/unknown_os_manager.rb +5 -8
  109. data/lib/autoproj/package_managers/yum_manager.rb +12 -15
  110. data/lib/autoproj/package_managers/zypper_manager.rb +11 -14
  111. data/lib/autoproj/package_manifest.rb +28 -74
  112. data/lib/autoproj/package_selection.rb +187 -187
  113. data/lib/autoproj/package_set.rb +145 -114
  114. data/lib/autoproj/python.rb +297 -0
  115. data/lib/autoproj/query_base.rb +20 -14
  116. data/lib/autoproj/reporter.rb +19 -19
  117. data/lib/autoproj/repository_managers/apt.rb +102 -68
  118. data/lib/autoproj/repository_managers/unknown_os_manager.rb +3 -3
  119. data/lib/autoproj/ros_condition_parser.rb +84 -0
  120. data/lib/autoproj/ros_package_manifest.rb +125 -0
  121. data/lib/autoproj/shell_completion.rb +16 -13
  122. data/lib/autoproj/source_package_query.rb +29 -36
  123. data/lib/autoproj/system.rb +32 -21
  124. data/lib/autoproj/test.rb +131 -106
  125. data/lib/autoproj/variable_expansion.rb +10 -10
  126. data/lib/autoproj/vcs_definition.rb +53 -37
  127. data/lib/autoproj/version.rb +1 -1
  128. data/lib/autoproj/workspace.rb +143 -108
  129. data/lib/autoproj/zsh_completion.rb +8 -9
  130. data/lib/autoproj.rb +55 -53
  131. data/samples/autoproj/init.rb +1 -2
  132. metadata +86 -65
  133. data/.travis.yml +0 -22
@@ -1,222 +1,222 @@
1
1
  module Autoproj
2
- # Class holding information about which packages have been selected, and
3
- # why. It is used to decide whether some non-availability of packages
4
- # are errors or simply warnings (i.e. if the user really wants a given
5
- # package, or merely might be adding it by accident)
6
- class PackageSelection
7
- include Enumerable
8
-
9
- # The set of matches, i.e. a mapping from a user-provided string to
10
- # the set of packages it selected
11
- attr_reader :matches
12
- # The set of selected packages, as a hash of the package name to the
13
- # set of user-provided strings that caused that package to be
14
- # selected
15
- attr_reader :selection
16
- # A flag that tells #filter_excluded_and_ignored_packages whether
17
- # the a given package selection is weak or not.
18
- #
19
- # If true, a selection that have some excluded packages will not
20
- # generate an error. Otherwise (the default), an error is generated
21
- attr_reader :weak_dependencies
22
- # After a call to #filter_excluded_and_ignored_packages, this
23
- # contains the set of package exclusions that have been ignored
24
- # because the corresponding metapackage has a weak dependency policy
25
- attr_reader :exclusions
26
- # After a call to #filter_excluded_and_ignored_packages, this
27
- # contains the set of package ignores that have been ignored because
28
- # the corresponding metapackage has a weak dependency policy
29
- attr_reader :ignores
30
- # The set of source packages that have been selected
31
- attr_reader :source_packages
32
- # The set of osdeps that have been selected
33
- attr_reader :osdeps
34
-
35
- def initialize
36
- @selection = Hash.new { |h, k| h[k] = Set.new }
37
- @matches = Hash.new { |h, k| h[k] = Set.new }
38
- @weak_dependencies = Hash.new
39
- @ignores = Hash.new { |h, k| h[k] = Set.new }
40
- @exclusions = Hash.new { |h, k| h[k] = Set.new }
41
- @source_packages = Set.new
42
- @osdeps = Set.new
43
- end
2
+ # Class holding information about which packages have been selected, and
3
+ # why. It is used to decide whether some non-availability of packages
4
+ # are errors or simply warnings (i.e. if the user really wants a given
5
+ # package, or merely might be adding it by accident)
6
+ class PackageSelection
7
+ include Enumerable
8
+
9
+ # The set of matches, i.e. a mapping from a user-provided string to
10
+ # the set of packages it selected
11
+ attr_reader :matches
12
+ # The set of selected packages, as a hash of the package name to the
13
+ # set of user-provided strings that caused that package to be
14
+ # selected
15
+ attr_reader :selection
16
+ # A flag that tells #filter_excluded_and_ignored_packages whether
17
+ # the a given package selection is weak or not.
18
+ #
19
+ # If true, a selection that have some excluded packages will not
20
+ # generate an error. Otherwise (the default), an error is generated
21
+ attr_reader :weak_dependencies
22
+ # After a call to #filter_excluded_and_ignored_packages, this
23
+ # contains the set of package exclusions that have been ignored
24
+ # because the corresponding metapackage has a weak dependency policy
25
+ attr_reader :exclusions
26
+ # After a call to #filter_excluded_and_ignored_packages, this
27
+ # contains the set of package ignores that have been ignored because
28
+ # the corresponding metapackage has a weak dependency policy
29
+ attr_reader :ignores
30
+ # The set of source packages that have been selected
31
+ attr_reader :source_packages
32
+ # The set of osdeps that have been selected
33
+ attr_reader :osdeps
34
+
35
+ def initialize
36
+ @selection = Hash.new { |h, k| h[k] = Set.new }
37
+ @matches = Hash.new { |h, k| h[k] = Set.new }
38
+ @weak_dependencies = Hash.new
39
+ @ignores = Hash.new { |h, k| h[k] = Set.new }
40
+ @exclusions = Hash.new { |h, k| h[k] = Set.new }
41
+ @source_packages = Set.new
42
+ @osdeps = Set.new
43
+ end
44
44
 
45
- def include?(pkg_name)
46
- selection.has_key?(pkg_name)
47
- end
45
+ def include?(pkg_name)
46
+ selection.has_key?(pkg_name)
47
+ end
48
48
 
49
- def empty?
50
- selection.empty?
51
- end
49
+ def empty?
50
+ selection.empty?
51
+ end
52
52
 
53
- # Test if a package is in the ignore list
54
- #
55
- # @param [String] pkg_name Name of the package
56
- # @return [Bool] true, if package is in the ignore list, false
57
- # otherwise
58
- def ignored?(pkg_name)
59
- ignores.include?(pkg_name)
60
- end
53
+ # Test if a package is in the ignore list
54
+ #
55
+ # @param [String] pkg_name Name of the package
56
+ # @return [Bool] true, if package is in the ignore list, false
57
+ # otherwise
58
+ def ignored?(pkg_name)
59
+ ignores.include?(pkg_name)
60
+ end
61
61
 
62
- # Test if a package is in the exclusions list
63
- #
64
- # @param [String] pkg_name Name of the package
65
- # @return [Bool] true, if package is in the exclusion list, false
66
- # otherwise
67
- def excluded?(pkg_name)
68
- exclusions.include?(pkg_name)
69
- end
62
+ # Test if a package is in the exclusions list
63
+ #
64
+ # @param [String] pkg_name Name of the package
65
+ # @return [Bool] true, if package is in the exclusion list, false
66
+ # otherwise
67
+ def excluded?(pkg_name)
68
+ exclusions.include?(pkg_name)
69
+ end
70
70
 
71
- # Returns the source packages selected explicitely or through
72
- # dependencies
73
- #
74
- # @param [Manifest] manifest
75
- # @return [Array<PackageDefinition>]
76
- def all_selected_source_packages(manifest)
77
- names = Set.new
78
- roots = each_source_package_name.to_set
79
- roots.each do |pkg_name|
80
- manifest.find_autobuild_package(pkg_name).all_dependencies(names)
81
- end
82
- names.merge(roots).map do |pkg_name|
83
- manifest.find_package_definition(pkg_name)
84
- end
71
+ # Returns the source packages selected explicitely or through
72
+ # dependencies
73
+ #
74
+ # @param [Manifest] manifest
75
+ # @return [Array<PackageDefinition>]
76
+ def all_selected_source_packages(manifest)
77
+ names = Set.new
78
+ roots = each_source_package_name.to_set
79
+ roots.each do |pkg_name|
80
+ manifest.find_autobuild_package(pkg_name).all_dependencies(names)
85
81
  end
86
-
87
- # Returns the source packages selected explicitely or through
88
- # dependencies
89
- #
90
- # @param [Manifest] manifest
91
- # @return [Array<String>]
92
- def all_selected_osdep_packages(manifest)
93
- all_sources = all_selected_source_packages(manifest)
94
- from_source = all_sources.each_with_object(Set.new) do |pkg, s|
95
- s.merge(pkg.autobuild.os_packages)
96
- end
97
- from_source | osdeps
82
+ names.merge(roots).map do |pkg_name|
83
+ manifest.find_package_definition(pkg_name)
98
84
  end
85
+ end
99
86
 
100
- def each(&block)
101
- Autoproj.warn_deprecated "PackageSelection#each", "use PackageSelection#each_source_package_name instead", 0
102
- each_source_package_name(&block)
103
- end
87
+ # Returns the source packages selected explicitely or through
88
+ # dependencies
89
+ #
90
+ # @param [Manifest] manifest
91
+ # @return [Array<String>]
92
+ def all_selected_osdep_packages(manifest)
93
+ all_sources = all_selected_source_packages(manifest)
94
+ from_source = all_sources.each_with_object(Set.new) do |pkg, s|
95
+ s.merge(pkg.autobuild.os_packages)
96
+ end
97
+ from_source | osdeps
98
+ end
104
99
 
105
- def each_package_name(&block)
106
- return enum_for(__method__) if !block
107
- each_source_package_name(&block)
108
- each_osdep_package_name(&block)
109
- end
100
+ def each(&block)
101
+ Autoproj.warn_deprecated "PackageSelection#each", "use PackageSelection#each_source_package_name instead", 0
102
+ each_source_package_name(&block)
103
+ end
110
104
 
111
- def selected_source_package?(pkg)
112
- source_packages.include?(pkg.name)
113
- end
105
+ def each_package_name(&block)
106
+ return enum_for(__method__) unless block
114
107
 
115
- def each_source_package_name(&block)
116
- source_packages.each(&block)
117
- end
108
+ each_source_package_name(&block)
109
+ each_osdep_package_name(&block)
110
+ end
118
111
 
119
- def each_osdep_package_name(&block)
120
- osdeps.each(&block)
121
- end
112
+ def selected_source_package?(pkg)
113
+ source_packages.include?(pkg.name)
114
+ end
122
115
 
123
- def packages
124
- Autoproj.warn_deprecated "PackageSelection#packages", "use PackageSelection#source_packages instead", 0
125
- source_packages
126
- end
116
+ def each_source_package_name(&block)
117
+ source_packages.each(&block)
118
+ end
127
119
 
128
- def select(sel, packages, *_backward, weak: false, osdep: false)
129
- unless _backward.empty?
130
- Autoproj.warn_deprecated "calling PackageSelection#select with a boolean as third argument", "use e.g. weak: true instead", 0
131
- weak = _backward.first
132
- end
120
+ def each_osdep_package_name(&block)
121
+ osdeps.each(&block)
122
+ end
133
123
 
134
- packages = Array(packages).to_set
135
- matches[sel].merge(packages)
136
- packages.each do |pkg_name|
137
- selection[pkg_name] << sel
138
- end
139
- if osdep
140
- osdeps.merge(packages)
141
- else
142
- source_packages.merge(packages)
143
- end
124
+ def packages
125
+ Autoproj.warn_deprecated "PackageSelection#packages", "use PackageSelection#source_packages instead", 0
126
+ source_packages
127
+ end
144
128
 
145
- weak_dependencies[sel] = weak
129
+ def select(sel, packages, *_backward, weak: false, osdep: false)
130
+ unless _backward.empty?
131
+ Autoproj.warn_deprecated "calling PackageSelection#select with a boolean as third argument", "use e.g. weak: true instead", 0
132
+ weak = _backward.first
146
133
  end
147
134
 
148
- def initialize_copy(old)
149
- old.selection.each do |pkg_name, set|
150
- @selection[pkg_name] = set.dup
151
- end
152
- old.matches.each do |sel, set|
153
- @matches[sel] = set.dup
154
- end
155
- @source_packages = old.source_packages.dup
156
- @osdeps = old.osdeps.dup
135
+ packages = Array(packages).to_set
136
+ matches[sel].merge(packages)
137
+ packages.each do |pkg_name|
138
+ selection[pkg_name] << sel
157
139
  end
158
-
159
- def has_match_for?(sel)
160
- matches.has_key?(sel)
140
+ if osdep
141
+ osdeps.merge(packages)
142
+ else
143
+ source_packages.merge(packages)
161
144
  end
162
145
 
163
- def match_for(sel)
164
- matches[sel]
146
+ weak_dependencies[sel] = weak
147
+ end
148
+
149
+ def initialize_copy(old)
150
+ old.selection.each do |pkg_name, set|
151
+ @selection[pkg_name] = set.dup
152
+ end
153
+ old.matches.each do |sel, set|
154
+ @matches[sel] = set.dup
165
155
  end
156
+ @source_packages = old.source_packages.dup
157
+ @osdeps = old.osdeps.dup
158
+ end
166
159
 
167
- # Remove packages that are explicitely excluded and/or ignored
168
- #
169
- # Raise an error if an explicit selection expands only to an
170
- # excluded package, and display a warning for ignored packages
171
- def filter_excluded_and_ignored_packages(manifest)
172
- matches.each do |sel, expansion|
173
- excluded, other = expansion.partition { |pkg_name| manifest.excluded?(pkg_name) }
174
- ignored, ok = other.partition { |pkg_name| manifest.ignored?(pkg_name) }
175
-
176
- if !excluded.empty? && (!weak_dependencies[sel] || (ok.empty? && ignored.empty?))
177
- exclusions = excluded.map do |pkg_name|
178
- [pkg_name, manifest.exclusion_reason(pkg_name)]
179
- end
180
- base_msg = "#{sel} is selected in the manifest or on the command line"
181
- if exclusions.size == 1
182
- reason = exclusions[0][1]
183
- if sel == exclusions[0][0]
184
- raise ExcludedSelection.new(sel), "#{base_msg}, but it is excluded from the build: #{reason}"
185
- elsif weak_dependencies[sel]
186
- raise ExcludedSelection.new(sel), "#{base_msg}, but it expands to #{exclusions.map(&:first).join(", ")}, which is excluded from the build: #{reason}"
187
- else
188
- raise ExcludedSelection.new(sel), "#{base_msg}, but its dependency #{exclusions.map(&:first).join(", ")} is excluded from the build: #{reason}"
189
- end
160
+ def has_match_for?(sel)
161
+ matches.has_key?(sel)
162
+ end
163
+
164
+ def match_for(sel)
165
+ matches[sel]
166
+ end
167
+
168
+ # Remove packages that are explicitely excluded and/or ignored
169
+ #
170
+ # Raise an error if an explicit selection expands only to an
171
+ # excluded package, and display a warning for ignored packages
172
+ def filter_excluded_and_ignored_packages(manifest)
173
+ matches.each do |sel, expansion|
174
+ excluded, other = expansion.partition { |pkg_name| manifest.excluded?(pkg_name) }
175
+ ignored, ok = other.partition { |pkg_name| manifest.ignored?(pkg_name) }
176
+
177
+ if !excluded.empty? && (!weak_dependencies[sel] || (ok.empty? && ignored.empty?))
178
+ exclusions = excluded.map do |pkg_name|
179
+ [pkg_name, manifest.exclusion_reason(pkg_name)]
180
+ end
181
+ base_msg = "#{sel} is selected in the manifest or on the command line"
182
+ if exclusions.size == 1
183
+ reason = exclusions[0][1]
184
+ if sel == exclusions[0][0]
185
+ raise ExcludedSelection.new(sel), "#{base_msg}, but it is excluded from the build: #{reason}"
190
186
  elsif weak_dependencies[sel]
191
- raise ExcludedSelection.new(sel), "#{base_msg}, but expands to #{exclusions.map(&:first).join(", ")}, and all these packages are excluded from the build:\n #{exclusions.map { |e_name, e_reason| "#{e_name}: #{e_reason}" }.join("\n ")}"
187
+ raise ExcludedSelection.new(sel), "#{base_msg}, but it expands to #{exclusions.map(&:first).join(', ')}, which is excluded from the build: #{reason}"
192
188
  else
193
- raise ExcludedSelection.new(sel), "#{base_msg}, but it requires #{exclusions.map(&:first).join(", ")}, and all these packages are excluded from the build:\n #{exclusions.map { |e_name, e_reason| "#{e_name}: #{e_reason}" }.join("\n ")}"
189
+ raise ExcludedSelection.new(sel), "#{base_msg}, but its dependency #{exclusions.map(&:first).join(', ')} is excluded from the build: #{reason}"
194
190
  end
191
+ elsif weak_dependencies[sel]
192
+ raise ExcludedSelection.new(sel), "#{base_msg}, but expands to #{exclusions.map(&:first).join(', ')}, and all these packages are excluded from the build:\n #{exclusions.map { |e_name, e_reason| "#{e_name}: #{e_reason}" }.join("\n ")}"
195
193
  else
196
- self.exclusions[sel] |= excluded.to_set.dup
197
- self.ignores[sel] |= ignored.to_set.dup
198
- end
199
-
200
- excluded = excluded.to_set
201
- ignored = ignored.to_set
202
- expansion.delete_if do |pkg_name|
203
- ignored.include?(pkg_name) || excluded.include?(pkg_name)
194
+ raise ExcludedSelection.new(sel), "#{base_msg}, but it requires #{exclusions.map(&:first).join(', ')}, and all these packages are excluded from the build:\n #{exclusions.map { |e_name, e_reason| "#{e_name}: #{e_reason}" }.join("\n ")}"
204
195
  end
196
+ else
197
+ self.exclusions[sel] |= excluded.to_set.dup
198
+ ignores[sel] |= ignored.to_set.dup
205
199
  end
206
200
 
207
- source_packages.delete_if do |pkg_name|
208
- manifest.excluded?(pkg_name) || manifest.ignored?(pkg_name)
209
- end
210
- osdeps.delete_if do |pkg_name|
211
- manifest.excluded?(pkg_name) || manifest.ignored?(pkg_name)
212
- end
213
- selection.delete_if do |pkg_name, _|
214
- manifest.excluded?(pkg_name) || manifest.ignored?(pkg_name)
215
- end
216
- matches.delete_if do |key, sel|
217
- sel.empty?
201
+ excluded = excluded.to_set
202
+ ignored = ignored.to_set
203
+ expansion.delete_if do |pkg_name|
204
+ ignored.include?(pkg_name) || excluded.include?(pkg_name)
218
205
  end
219
206
  end
207
+
208
+ source_packages.delete_if do |pkg_name|
209
+ manifest.excluded?(pkg_name) || manifest.ignored?(pkg_name)
210
+ end
211
+ osdeps.delete_if do |pkg_name|
212
+ manifest.excluded?(pkg_name) || manifest.ignored?(pkg_name)
213
+ end
214
+ selection.delete_if do |pkg_name, _|
215
+ manifest.excluded?(pkg_name) || manifest.ignored?(pkg_name)
216
+ end
217
+ matches.delete_if do |key, sel|
218
+ sel.empty?
219
+ end
220
220
  end
221
+ end
221
222
  end
222
-