[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Package integration date into repository



Hi Marco,

25 avr. 2020 à 23:12 de talby@debianlists.mobilxpress.net:

> To receive the date from the changelog is the closest I would know of, after I for myself have been searching for this in the past. I then constructed some ugly but well working CLI (bash) command:
>
> apt-get changelog PACKAGENAME 2> /dev/null| grep -m 1 "^ --" 2> /dev/null| cut -d'>' -f2 2> /dev/null| cut -c 3- 2> /dev/null | cut -d' ' --complement -s -f6 2> /dev/null
>
I didn't know about apt(-get) changelog, thank you :)
However, I note there is no direct command to obtain the expected result according to you.
NB: I have a suggestion for your command, same logic but probably less resource-consuming because there is only one pipe:
apt-get changelog PACKAGENAME 2>/dev/null | awk 'BEGIN{FS=">"} /--/{sub("  ","",$2);print $2;exit}'

Best regards,
l0f4r0


Reply to: