Use an OS where common commands in Windows/Linux do not work.
Use an OS that can not/will not run the virus code these USBs try to plant.