In matters of style, swim with the current; In matters of principle, stand like a rock.

Thomas Jefferson (1743-1826) American political philosopher, polymath, statesman, US President (1801-09)
(Spurious)

A common phrase in the late 19th Century. Only associated with Jefferson as of the mid-20th Century.