preventing the script from showing all the packages when there's an error
switched sed with awk