This one dont drop a target if you got one already targeted.
#showtooltip judgement
/console targetNearestDistance 15,000000
/targetenemy [noharm][dead]
/console targetNearestDistance 41.000000
/cast judgement
/startattack
Im not 100% sure if it should be "/console targetNearestDistance 15,000000" or "/console targetNearestDistance 10,000000" but I think 15 is better. But im not really sure what it do and I remember seeing a post about that "this" have been normalized.
My favorite: This one drop target and retarget the closest (also this macro can only target players with "/targetenemyplayer" soo you cant target pets or totems).
#showtooltip judgement
/cleartarget
/targetenemyplayer
/cast judgement
/startattack