Get All Tags Of All Tests Inside Folder recursively

Right now i configuring jenkins, and i want to run tests using tags, but i don’t understand how to get all tags of current tests and save them into file. Can someone help me ?

If you do a --dryrun you will have all assigned tags at the statistics. In log.html and in output.xml

robot --dryrun suite_folder

in the XML the tags are also at one place.
/robot/statistics/tag

Like this:

<tag>
  <stat pass="1" fail="0">DEFAULT</stat>
  <stat pass="1" fail="0">fail</stat>
  <stat pass="2" fail="0">FORCE</stat>
  <stat pass="2" fail="0">FORCE2</stat>
  <stat pass="1" fail="0">getagged</stat>
  <stat pass="1" fail="0">TAG</stat>
  <stat pass="1" fail="2">Test</stat>
</tag>
1 Like

Thanks that kind of a listener is already done but before posting here i searched the web and found an article on stackoverflow with code snippet that does it without dry run of all tests. Unluckily for me this code is for old robot api maybe someone can help me to adopt it to new robot ?