Both ways, but there are two behaviors from the command line.
If I run the utility before signing and notarization, Gatekeeper blocks it. Signing and notarization doesn't help.
If I just download it, sign it, zip it, notarize it and then run it from the command, then Gatekeeper stays quiet and it works as it should.
...and yes, double-clicking from Finder, I get the issue as described in the post you refer to. I had read it, but too much text, so I missed the critical part ;-) .