This is mainly for EPEL10 planning, but others might find it useful, so I'm sending it to the email vs the epel10 discussion on discourse.
I was talking with Carl about creating a dnf variable for the epel 10 repos. He had been talking about using $releasever and $releaseminor. But we also talked about creating our own epel variable. This is about creating our own epel variable. I'm calling it epelrelease but that it up for debate.
There is an often overlooked file called /etc/os-release It's full of lots of good stuff, including a variable called "VERSION_ID" In every Red Hat compatible release (Fedora, Stream, RHEL, Alma, Rocky) this should give us what we need/want. Fedora 39 Stream 8 / 9 RHEL 8.7 / 9.1 Alma 8.7 / 9.1 Rocky 8.7 / 9.1
The format of /etc/os-release makes it very easy to use. The following would give us a dnf variable called epelrelease
source /etc/os-release ; echo $VERSION_ID >> /etc/dnf/vars/epelrelease
We could then use epelrelease in our dnf configs.
How to set it, I suggest triggers. But that needs a bit more investigation and testing.
Troy
Dne 31. 03. 23 v 16:42 Troy Dawson napsal(a):
How to set it, I suggest triggers. But that needs a bit more investigation and testing.
May I suggest file trigger?
https://rpm-software-management.github.io/rpm/manual/file_triggers.html
Miroslav
On Fri, Mar 31, 2023 at 11:19 AM Miroslav Suchý msuchy@redhat.com wrote:
Dne 31. 03. 23 v 16:42 Troy Dawson napsal(a):
How to set it, I suggest triggers. But that needs a bit more
investigation and testing.
May I suggest file trigger?
https://rpm-software-management.github.io/rpm/manual/file_triggers.html
Miroslav
I've learned something new today. Yes, that is exactly what we need.
Troy
epel-devel@lists.fedoraproject.org