As T-90 mentioned, It depends on the map and the amount of resources available + your opponent's style of play and your own strategy, but generally:
Power, barracks, refinery, power, war factory, battle lab, nuclear reactor, industrial plant, service depot.
If you know that they play mostly defensive, and that they won't rush you; focus on making as much money as you can first; take oil rigs, make more miners (or build power plants, if they generate money, like on some mod maps) while they don't have the means to attack, then make sure you have enough defenses at base before you finally attack.
Running low on power will slow you down significantly, so always keep some green in your power bar (build more power plants before it turns yellow).
If you need to make several miners urgently, you can build refineries while making miners, and then you can sell the extra refineries.
If you wanna rush and you have enough money, you should build several war factories to produce tanks more quickly, and if you don't have the money, you can sell some buildings (even MCV) to buy more tanks ASAP, but that's a risky strategy, and it's very unlikely to work unless it's a 1v1.
If your opponent tends to rush, you need to make defenses ASAP, and not waste time making other things, like too many miners.
It's very important to know what your opponent is doing all the time, so you need to unshroud their base ASAP (with a dog or whatever), and use a SpySat when available, to predict what they're up to and be ready for it.
You need to be ready to counter anything your opponent could do at any time, so the more prepared to attack they are, the more prepared you should be to defend, and the less prepared to defend they are, the more prepared you should be to attack.
I could write a very thick book on tips & strategies for both beginners and advanced players.
But again, as T-90 mentioned, getting experience is the best way to learn.
Watching experienced players can teach you a lot as well.
Now, without checking; how many times have I said "If" & "ASAP"?
GL HF.