On 11/13/20 6:28 PM, harry devine wrote:
> So how do I get rid of the u? What I ultimately wanted was JUST the email addresses.
>
> Harry
Join the list members into a string: | join('\n')
Regards
Racke
> > [
u'us...@example.com <mailto:
u%27u...@example.com>',
u'us...@example.com <mailto:
u%27u...@example.com>']
> >
> > Harry
> >
> > On Friday, November 13, 2020 at 11:13:27 AM UTC-5
dick....@geant.org <mailto:
dick....@geant.org> wrote:
> >>
> >> On Fri, 13 Nov 2020 at 16:48,
lift...@gmail.com <mailto:
lift...@gmail.com> <
lift...@gmail.com
> <mailto:
lift...@gmail.com>> wrote:
> >>
> >> >> >> >> > - name: Set User Email fact
> >> >> >> >> > set_fact:
> >> >> >> >> > user_list: "{{ user_find.json.result | json_query('result[].mail') | list | to_nice_yaml }}"
> >>
> >> Try adding a pipe expression to the query, and leave out the
> >> 'list|to_nice_yaml':
> >>
> >>
> >> set_fact:
> >> user_list: "{{ user_find.json.result | json_query('result[].mail[]') }}"
> >>
> >>
> >>
> >> Dick
> >
> > --
> > You received this message because you are subscribed to the Google Groups "Ansible Project" group.
> > To unsubscribe from this group and stop receiving emails from it, send an email to
>
ansible-proje...@googlegroups.com <mailto:
ansible-project%2Bunsu...@googlegroups.com>.
> <
https://groups.google.com/d/msgid/ansible-project/e2de7a54-ba5d-4677-aaa6-9fd5cc83b522n%40googlegroups.com>.
>
>
>
> --
> Dick Visser
> Trust & Identity Service Operations Manager
> GÉANT
>
> --
> You received this message because you are subscribed to the Google Groups "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
>
ansible-proje...@googlegroups.com <mailto:
ansible-project%2Bunsu...@googlegroups.com>.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/ansible-project/CAL8fbwMh9wong6MUnMHvZBs5AbpWogzD%3DYjQMLWOxNC0YebDEQ%40mail.gmail.com
> <
https://groups.google.com/d/msgid/ansible-project/CAL8fbwMh9wong6MUnMHvZBs5AbpWogzD%3DYjQMLWOxNC0YebDEQ%40mail.gmail.com>.
>
> --
> You received this message because you are subscribed to the Google Groups "Ansible Project" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
>
ansible-proje...@googlegroups.com <mailto:
ansible-proje...@googlegroups.com>.
> To view this discussion on the web visit
>
https://groups.google.com/d/msgid/ansible-project/CALYKJ268J-TnW1RGcahzQGfBeU9dHRRX_giohJ0%3DXuC9gfK-6A%40mail.gmail.com
> <
https://groups.google.com/d/msgid/ansible-project/CALYKJ268J-TnW1RGcahzQGfBeU9dHRRX_giohJ0%3DXuC9gfK-6A%40mail.gmail.com?utm_medium=email&utm_source=footer>.