I guess you are asking for MacOs because by default shortcut for code formatting is different for different Os.
Now there might be an issue with the keyboard layout.
For example Option+Shift+F does not work in ABC-Indian layout, you need to change that.
Go to System-prefrences->Keyboard->Input Sources-> Add layout “ABC” and delete the old one.