Parse registered output into a variable?

Hello - Is there a way to parse registered output into a variable?

Pseudo Code:

`
tasks:

  • name: Sample Task
    command: ‘blah’
    register: output
  • debug: var=output.stdout

`

TASK [debug] *******************************************************************
ok: [target] => {
“output.stdout”: “Foo: Bar”
}

So I can easily register and use “Foo: Bar”. But is there a way where I can just store “Bar” for later use?
For context, the command uses some black box vendor provided classes so I’m unable to change the actual output. I need to work with what is presented.

Thank you!

set_fact:
just_bar: “{{ output.stdout.split()|last }}”

Or any other number of things. The key there is to use set_fact to set a new variable.

Ah - works like a charm. Thank you for the speedy response!