Key '@' (Keycode 49) and key '<' (keycode 94) are inverted on macbookPro keyboard

Solution 1:

I accidentally stumbled upon this patch, which led me to the solution:

Open /etc/default/keyboard for editing and set:

XKBOPTIONS="apple:badmap"

At next reboot those keys will be switched.