View previous topic :: View next topic |
Author |
Message |
krinn Watchman
Joined: 02 May 2003 Posts: 7470
|
Posted: Wed Sep 01, 2010 11:47 am Post subject: re-emerge packages that were emerge on a date |
|
|
It's not really useful, only some users might need it for a special purpose (usage is too uncommon)
I use it to revert my packages build against a newer glibc version after i didn't catch a glibc upgrade was in my -uDN world list (and i don't want to -e world for just the few packages that were build with it)
This might be useful for people that use automatic update script. Or build pkg for packages that were emerge without -b options by that time. Or a cflags player that change his mind...
Anyway, as i said, uncommon usage, just a low tip except for the weirdo that keep experimenting with portage.
Now that you get the picture, re-emerge all the packages that were emerge on a fixed date
See the commands list first (for the wises who check before doing havoc)
genlop -l --date 08/31/2010 --date 09/01/2010 -n | grep "*" -v | sed 's/[a-zA-Z0-9].*>>> /=/' | uniq | xargs -I {} echo emerge -1 {}
really re-emerge them
genlop -l --date 08/31/2010 --date 09/01/2010 -n | grep "*" -v | sed 's/[a-zA-Z0-9].*>>> /=/' | uniq | xargs -I {} emerge -1 {}
note1: need emerge log feature & genlop (in portage)
note2: thanks to genlop you can use date range as --date 10 days ago --date now ... check genlop manual
note3: as you seen, emerge is run package by package, slower than emerging all packages at once (--jobs & parallelism users will loose the feature), but it's to avoid two programs with different version emerge at that date that would make emerge complaining about slot conflicts.
ie: on same date, emerge openssh-5.4 and openssh-5.5 would end up with "emerge =openssh-5.5 =openssh5.4" = slots conflict
this way you'll get "emerge =openssh5.5 && emerge =openssh5.4"
- You can use the xargs -P to run multi-emerge at once as (4 emerge in that example)
genlop -l --date 08/31/2010 --date 09/01/2010 -n | grep "*" -v | sed 's/[a-zA-Z0-9].*>>> /=/' | uniq | xargs -P 4 -I {} emerge -1 {}
- Or if you know it's not your case you can use that "i have no slot conflict" version instead :
see: genlop -l --date 08/31/2010 --date 09/01/2010 -n | grep "*" -v | sed 's/[a-zA-Z0-9].*>>> /=/' | uniq | xargs emerge -pv
run: genlop -l --date 08/31/2010 --date 09/01/2010 -n | grep "*" -v | sed 's/[a-zA-Z0-9].*>>> /=/' | uniq | xargs emerge -1 |
|
Back to top |
|
|
Bones McCracker Veteran
Joined: 14 Mar 2006 Posts: 1611 Location: U.S.A.
|
Posted: Fri Sep 10, 2010 8:30 am Post subject: |
|
|
Thanks for recording it here. You'll save some poor droog hours of fumbling about. _________________
patrix_neo wrote: | The human thought: I cannot win.
The ratbrain in me : I can only go forward and that's it. |
|
|
Back to top |
|
|
kernelOfTruth Watchman
Joined: 20 Dec 2005 Posts: 6111 Location: Vienna, Austria; Germany; hello world :)
|
|
Back to top |
|
|
krinn Watchman
Joined: 02 May 2003 Posts: 7470
|
Posted: Mon Sep 13, 2010 4:26 pm Post subject: |
|
|
ah thank you guys, warming my heart seeing that. |
|
Back to top |
|
|
|