Price gouging will be illegal from July 1 in the government's crackdown on price increases in supermarkets.