# yum history

**URL:** <https://forum.ansible.com/t/yum-history/31081>\
**Category:** Ansible Project\
**Created:** [August 20, 2019, 8:35pm UTC](https://forum.ansible.com/t/yum-history/31081 "2019-08-20T20:35:06Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Amos](https://avatars.discourse-cdn.com/v4/letter/a/ebca7d/32.png) [@Amos](https://forum.ansible.com/u/Amos)\
**Post date:** [August 20, 2019, 8:35pm UTC](https://forum.ansible.com/t/yum-history/31081/1 "2019-08-20T20:35:06Z")

</div>

So, in bash I can get some info from ‘yum history’.

Get the last ‘yum update’:

yum history | grep Update | head -1

Get the very last call to yum:

yum history | awk ‘/^----/{ n=NR+1 }n && n\<=NR && NR\<(n+1){ print }’

How do I parse that with an ansible regex?
