Here's what I've got for a Prusa i3 Mk3 (edited down to show warmups only). I raise the nozzle for inspection and bed cleaning, then set the nozzle up to a no-ooze temp and set the bed to a warming temp for the PINDA leveling probe . This has the side benefit of waiting to cool down to this temp if the nozzle is hot, which is good for the Prusa PINDA probe. I then drop the nozzle near the bed center for warming the PINDA probe (consistent temp yields consistent results). Once it's warmed, I re-home, set final bed and nozzle temps, wait for them to warm up, then print the prime line and go.
; Last updated 20180910
M104 S140 ; Set nozzle no-ooze warmup temp
M140 S65 ; set bed PINDA warmup temp
G28 W ; home all without mesh bed level
G0 X0 Y200 Z100.0 F1000 ; raise nozzle and present bed for cleaning
M109 ; wait for extruder no-ooze warmup temp before mesh bed leveling, cool hot PINDA
G0 X125 Y105 Z0.10 F1000; PINDA warming position
M190 S65 ; wait for bed PINDA warmup temp
M860 S35 ; wait for PINDA temp to stabilize
G28 W ; home all without mesh bed level
G80 ; mesh bed leveling
M140 S{material_bed_temperature_layer_0} ; set bed final temp
M104 S{material_print_temperature_layer_0} ; set extruder final temp
M109 S{material_print_temperature_layer_0} ; wait for extruder final temp
M190 S{material_bed_temperature_layer_0} ; wait for bed final temp
; Print prime line
G92 E0.0 ; reset extrusion distance
G1 Y-3.0 F1000.0 ; go outside print area
G1 X20.0 E6 F1000.0 ; 20mm intro line @ 0.30
G1 X60.0 E3.2 F1000.0 ; +40mm intro line @ 0.08
G1 X100.0 E6 F1000.0 ; +40mm intro line @ 0.15
G1 E-1.0 F900; retract to avoid string
G1 X95.0 E0 F1000.0 ; -5mm intro line @ 0.00
G1 X106.0 E0 F1000.0 ; +6mm intro line @ 0.00
G92 E0.0 ; reset extrusion distance
M82 ; absolute extrusion mode