@elextr well, I don't see a reason why it wouldn't work anywhere that has a POSIX shell. Windows doesn't by default, but I don't see why it wouldn't with MSYS2 or something. What I suggest here also works with Dash (at least the very line I change), so it should be pretty safe.