Skip to content
This repository has been archived by the owner on Nov 20, 2023. It is now read-only.

Commit

Permalink
feat: install repos first, so that they're available for scripting
Browse files Browse the repository at this point in the history
This ensures that custom scripts have the flexibility to work with the repos that have been added.
  • Loading branch information
Arcitec authored and xynydev committed May 10, 2023
1 parent f24c407 commit d09dd76
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand All @@ -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 \
Expand Down

0 comments on commit d09dd76

Please sign in to comment.