You should be careful not to catch a cold.

Literal

Cold [object-を] catch-not [purpose-ように] careful should.

気を付けるべきだ uses べきだ for strong recommendation — 'should be careful.' More forceful than the softer ~た方がいい ('would be better to'), expressing moral or social obligation.