Skip to content

Commit

Permalink
New dnf config-manager syntax
Browse files Browse the repository at this point in the history
Fedora 41 and Rawhide changed the package manager from dnf to dnf5
  • Loading branch information
voegelas committed Dec 3, 2024
1 parent 012f2cb commit ab9044e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/views/download/package.erb
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,9 @@ pacman -Sy <%= repo_name %>/<%= @package %></pre>
"zypper addrepo #{v[:repo]}#{@project}.repo\nzypper refresh\nzypper install #{@package}"
when 'Fedora'
version = k.split("_").last
if version == "Rawhide" or Integer(version) >= 22
if version == "Rawhide" or Integer(version) >= 41
"dnf config-manager addrepo --from-repofile=#{v[:repo]}#{@project}.repo\ndnf install #{@package}"
elsif Integer(version) >= 22
"dnf config-manager --add-repo #{v[:repo]}#{@project}.repo\ndnf install #{@package}"
else
"cd /etc/yum.repos.d/\nwget #{v[:repo]}#{@project}.repo\nyum install #{@package}"
Expand Down

0 comments on commit ab9044e

Please sign in to comment.