'remove all git tags cross-platform

I'm trying to remove all local and remote git tags I found several methods to accomplish this, but none of them works natively for cross-platforms

for example: in windows

git tag -d $(git tag -l) causes the error:

`switch `l' : incompatible with --delete`

git tag -l | xargs git tag -d causes 'xargs' is not recognized as an internal or external command

this worked in windows but fails in linux for /f "tokens=* delims=" %a in ('git tag -l') do git tag -d %a

I'm looking for a command to delete all git tags (locally and remotely) in cross-platform

git


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source