Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
etersoft-build-utils
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
korinf
etersoft-build-utils
Commits
527aceca
Commit
527aceca
authored
Feb 07, 2026
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rpmgp: group Repology results by repo like local results
parent
e1f9ccad
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
6 deletions
+10
-6
rpmgp
bin/rpmgp
+10
-6
No files found.
bin/rpmgp
View file @
527aceca
...
...
@@ -67,14 +67,18 @@ search_repology()
# check valid JSON
jq empty
"
$TMPJSON
"
2>/dev/null
||
{
rm
-f
"
$TMPJSON
"
;
return
1
;
}
local
RESULTS
# filter to rpm-based
and major distros only
RESULTS
=
$(
jq
-r
'to_entries[] | .
key as $proj | .value[] | select(.repo | test("^(alt|fedora|epel|elrepo|rosa|mageia|openmandriva|opensuse|suse|pld|centos|rhel|scientific|oracle|rocky|alma|amazon|pclinuxos)")) | $proj + "\t" + .repo + "\t" + (.srcname // .binname // .name) + "\t" + (.origversion // .version) + "\t" + .status
'
"
$TMPJSON
"
|
sort
-u
)
# filter to rpm-based
distros, output: repo\tsrcname-version.src.rpm
RESULTS
=
$(
jq
-r
'to_entries[] | .
value[] | select(.repo | test("^(alt|fedora|epel|elrepo|rosa|mageia|openmandriva|opensuse|suse|pld|centos|rhel|scientific|oracle|rocky|alma|amazon|pclinuxos)")) | .repo + "\t" + (.srcname // .binname // .name) + "-" + (.origversion // .version) + ".src.rpm"
'
"
$TMPJSON
"
|
sort
-u
)
rm
-f
"
$TMPJSON
"
[
-n
"
$RESULTS
"
]
||
return
1
echo
echo
"Repology results for '
$SPKGNAME
':"
echo
"
$RESULTS
"
|
while
IFS
=
' '
read
-r
proj repo srcname version status
;
do
printf
" %-25s %-25s %-25s %s (%s)
\n
"
"
$proj
"
"
$repo
"
"
$srcname
-
$version
"
"
$version
"
"
$status
"
local
lastrepo
=
echo
"
$RESULTS
"
|
while
IFS
=
' '
read
-r
repo srcrpm
;
do
if
[
"
$repo
"
!=
"
$lastrepo
"
]
;
then
echo
echo
"List for
$repo
(repology):"
lastrepo
=
"
$repo
"
fi
echo
"
$srcrpm
"
done
return
0
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment