Shabbat is like a flag of the people of Israel. One who desecrates it in public, even only for his desire, uproots the foundation, and his law is like a non-Jew. According to the Ramban and the Ran, his wine is forbidden like stam yeinam, but his baking and cooking are permitted, because nissuch and intermarriage do not apply there.