He mentions the usefulness of this wisdom in directing our actions when he says, and whatever you do, in word or deed, do everything in the name of the Lord Jesus Christ, because even our speaking is a work: "Whether you eat or drink, or whatever you do, do all to the glory of God" (1 Cor 10:31). Some find a difficulty in this statement of Paul: for what he is saying is either a command or a counsel. If it is a command, then whoever does not do this sins; yet a person sins venially when he does not do this; therefore, whoever sins venially sins mortally. My answer is this: Some say that this i...s a counsel; but this is not true. Nevertheless, it is not necessary that we refer everything to God in an actual way; it can be done habitually. Whoever acts against the glory of God and his commands, acts against this command. But one who sins venially does not act against this command in an absolute way, because even though he does not refer everything to God in an actual way, he does so habitually.
Source: Commentary on Colossians