You are not logged in.
I have decided to write this script for myself after I have recently upgraded my system and (foolishly) removed pacman.log in the meantime. The system crashed and I had no real idea which package upgrade might have been the cause. Thus, this software.
The main idea is to allow the user to quickly check what changes were made to local packages since a given day. Usage:
jakpak -d 05-07-2014 -r core
will provide the user with the list of packages (with their respective versions) that differ between the local system and the particular date specified by the user.
Apparently, the code needs some tuning, therefore if anyone would be interested in using this piece of software, this will follow up in due course. The same applies to a PKGBUILD.
Github link with installation instructions.
Please let me know whether you find it useful!
Offline
Why do you remove pacman.log?? Is this some kind of regular thing you do?
What about backups? You don't back /etc up?
Offline
I removed it in the routine of cleaning up, I do not backup logs from my desktop as I do not need them. Also, /etc does not have anything to do with the above.
Offline
Also, /etc does not have anything to do with the above.
True. I somehow conflated /var/log with /etc ...
$ echo $(date -d 'last Thursday' +%s)
1404943200
$ expac --timefmt=%s '%l %n' | awk '$1>=1404943200 {print $2}'
shaman-git
Somebody can probably turn this into a neat oneliner.
Offline
Indeed, that is nice.
Offline
$ cat foo
#!/bin/bash
datesec=$(date -d "$*" +%s)
expac --timefmt=%s '%l %n' | awk -v a=$datesec '$1>=a {print $2}'
$ ./foo last thursday
shaman-git
I haven't tested it at all, but seems to be somewhat functional.
Offline
The listing is alphabetical:
$ ./foo Thu Jul 09 21:29:43 CEST 2014
shaman-git
$ ./foo Thu Jul 09 11:29:43 CEST 2014
flashplugin
imagemagick
intel-dri
libsystemd
mesa
mesa-libgl
shaman-git
systemd
systemd-sysvcompat
xorg-xkbcomp
You may want to sort it e.g. from the oldest to the most recent:
$ cat bar
#!/bin/bash
datesec=$(date -d "$*" +%s)
expac --timefmt=%s '%l %n' | sort -n | awk -v a=$datesec '$1>=a {print $2}'
(just added 'sort -n' before the awk part)
Date has to be in a certain format for the script to work:
$ ./foo 11/07/2014
$ ./foo Jul 11
shaman-git
Offline