Skip to content

Commit

Permalink
Select the base product for evaluating the addon dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
lslezak committed Jul 9, 2019
1 parent 769a685 commit 0068dfc
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/include/packager/repositories_include.rb
@@ -1,5 +1,6 @@

require "y2packager/product_location"
require "y2packager/product"

# encoding: utf-8
module Yast
Expand Down Expand Up @@ -341,9 +342,15 @@ def autorefresh_for?(url)
# scan the repository URL and return the available products
# @return [Array<Y2Packager::ProductLocation>] Found products
def scan_products(_expanded_url, original_url)
# TODO: use the selected base product during installation,
# use the selected base product during installation,
# in installed system use the installed base product
base_product = "SLES" # Stage.initial ? ...
base_product = if Stage.initial
Y2Packager::Product.selected_base.name
else
Y2Packager::Product.installed_base_product.name
end

log.info("Using base product: #{base_product}")
found_products = Y2Packager::ProductLocation.scan(original_url, base_product)
log.info("Found products: #{found_products}")

Expand Down

0 comments on commit 0068dfc

Please sign in to comment.