Regarding the circuit in #2, three things:
1. Because a GPIO pin can both source and sink current, you do not need R5 to assure the complete and rapid turn-off of Q1.
2. If you replace Q1 with a 2N7000 small MOSFET, you can eliminate R4. A small MOSFET in this application does not need a current limiting or EMI suppression resistor at its gate.
3. R1 and R2 form a voltage divider across M1, reducing the gate drive voltage. In a 12 V system, Vgs is reduced to 8 V. With a FET rated for 20 volts Vgs, I would eliminate R2 and drive the M1 gate directly. With the increased Vgs, you now are not limited to using a logic-level MOSFET, as most "normal" power MOSFETs are rated for full enhancement (minimum Rdson) with Vgs = 10 V.
Regarding post #1, 220 ohms is a very low value for a gate turn-off resistor. You are correct that one is needed, but something in the 1 K to 10 K range is much more common. As the resistor value gets smaller, the collector or drain current and the power dissipation in the driver transistor increases. At 220 ohms, you are unnecessarily sinking over 50 mA.
For minimum ratings, a very common industry rule of thumb is 2x.
12 V circuit = 25 V (or higher) voltage rating for semiconductors, capacitors, etc.
1.25 A = 3 A or higher current rating for semiconductors, capacitors, connector pins, etc.
1 W power dissipation (resistors, FETs, whatever) = 2 W or higher components.
etc.
Also, in a p-channel MOSFET the body diode "points" toward the source. You do not need an external diode to prevent unwanted conduction through the body diode unless the load device or circuit has significant energy-storage capability (such as a large input capacitor) and the 12 V source can go low enough to cause enough reverse current to matter. This is a relatively rare condition. and should not come up when simply powering an inductor.
ak