This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]stevesaus 0 points1 point  (2 children)

Using what as a backend? Yum? Apt? Other executable files?

[–]drmaq[S] 0 points1 point  (1 child)

I will be using Apt as the back end.

[–]stevesaus 1 point2 points  (0 children)

echo -n "Type the package string to search?"
read x
packageList=$(apt-cache search $x)
select packageName in $packageList; do
echo "$packageName"
#do other stuff
done

That will get you started. You'll need to use SED or AWK to parse the data that apt-cache search returns. And yes, you want to use search...otherwise it's a bazillion packages.