Publishing a fat jar to a Maven repository actually is pretty much non-sense.
It is against the nature of a Maven repository where you have your jar and metadata that describes the dependencies you have so that a proper tool like Grale or Maven or Ivy could get them all.
But anyway, your exclude of course does nothing, what should it do.
By using @jar you already said you only want the jar and none of its dependencies.
That’s equal to excluding everything, so there is nothing more you could exclude.
There is no built-in means to exclude files from within a JAR as that is generally a horrible idea, as is depending on far jars - especially without shading - that could easily get you into trouble.
If you want to exclude files from the artifact, you need to use an artifact transform that does this.