From d09dd7624355076616735f82e066f364c0d02470 Mon Sep 17 00:00:00 2001 From: Arcitec <38923130+Arcitec@users.noreply.github.com> Date: Tue, 9 May 2023 15:41:11 +0200 Subject: [PATCH] feat: install repos first, so that they're available for scripting This ensures that custom scripts have the flexibility to work with the repos that have been added. --- build.sh | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/build.sh b/build.sh index 65961a85e6..54f177bbfb 100644 --- a/build.sh +++ b/build.sh @@ -3,6 +3,16 @@ # Tell build process to exit if there are any errors. set -ouex pipefail +# Add custom repos. +repos=$(yq '.extrarepos[]' < /usr/etc/ublue-recipe.yml) +if [[ -n "$repos" ]]; then + echo "-- Adding repos defined in recipe.yml --" + for repo in $(echo -e "$repos"); do \ + wget $repo -P /etc/yum.repos.d/; \ + done + echo "---" +fi + # Run scripts. echo "-- Running scripts defined in recipe.yml --" buildscripts=$(yq '.scripts[]' < /usr/etc/ublue-recipe.yml) @@ -15,15 +25,7 @@ echo "---" # Remove the default firefox (from fedora) in favor of the flatpak. rpm-ostree override remove firefox firefox-langpacks -repos=$(yq '.extrarepos[]' < /usr/etc/ublue-recipe.yml) -if [[ -n "$repos" ]]; then - echo "-- Adding repos defined in recipe.yml --" - for repo in $(echo -e "$repos"); do \ - wget $repo -P /etc/yum.repos.d/; \ - done - echo "---" -fi - +# Install RPMs. echo "-- Installing RPMs defined in recipe.yml --" rpm_packages=$(yq '.rpms[]' < /usr/etc/ublue-recipe.yml) for pkg in $(echo -e "$rpm_packages"); do \