I'm trying to create a list of installed packages, sorted by timestamp... And I came up with a script, but it's not working right:
%t is the timestamp, and it needs to correspond to $1. $port needs to correspond to $2. That way, the output can be sorted properly.
FWIW, this is a 6-year-old issue, discussed on FreeBSD's email lists... and not solved.
I'm open to using sed or whatever instead of awk, if that helps. If somebody can correct my script, I'd appreciate this!
Bash:
for port in `cat ../lists/kde_ports.txt`;
do
pkg query %t $port | awk '{ print $1" " $2}' | sort > ../lists/sorted_kde_ports.txt ;
done
%t is the timestamp, and it needs to correspond to $1. $port needs to correspond to $2. That way, the output can be sorted properly.
FWIW, this is a 6-year-old issue, discussed on FreeBSD's email lists... and not solved.
I'm open to using sed or whatever instead of awk, if that helps. If somebody can correct my script, I'd appreciate this!