mirror of
https://github.com/sbopkg/sbopkg
synced 2024-11-10 03:50:33 +03:00
Fix slack-desc parsing regression from r361
Prior to r361, there were two places where the slack-desc was parsed: in the "package browser" and in the "search results". r361 tossed most of the "package browser" code, including that part. It happens that the two implementation were different, and of course the removed one was the better of the two. This patch applies a further improved implementation to the current code. Thanks to "jsunx1" for providing the original implementation and for pointing out the regression. Thanks to Chess Griffin for preparing and sending me a patch restoring the old behavior. Signed-off-by: Mauro Giachero <mauro.giachero@gmail.com>
This commit is contained in:
parent
f5af902be3
commit
3c9b3d9742
@ -1568,8 +1568,8 @@ gen_search_package () {
|
||||
if [ "$DIAG" = 1 ]; then
|
||||
for i in $RESULTS; do
|
||||
DESC=$(grep -hZm1 ^$(echo "$i" |
|
||||
cut -d/ -f2) ./$i/slack-desc* | cut -d\( -f2- |
|
||||
cut -d\) -f1)
|
||||
cut -d/ -f2) ./$i/slack-desc* |
|
||||
sed 's/^[^(]*( *\(.*[^ ]\) *)[^)]*$/\1/')
|
||||
if [[ "$CATEGORY" = "*" ]]; then
|
||||
NAME=$i
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user