A pair of burglars from Birmingham were caught after they stopped a tractor driver in Sherston to ask if he could get them some red diesel.
The pair had just ransacked a family home, ripping open Christmas presents in their hunt for things to steal, before trying to refuel for the journey home.
Stephen Rosindale, 29, and Michael Nelson, 25, also flogged off thousands of pounds worth of jewellery on the cheap after stopping passers by in a Malmesbury car park.
But the hapless thieves were caught walking towards Kemble after asking other locals where the nearest train station was.
Colin Meeke, prosecuting, told Swindon Crown Court yesterday how the Midlanders drove to Yatton Keynell in a stolen silver Vauxhall Astra on Monday December 9.
They kicked in the door of a large detached house on the edge of the village before turning the inside of the house upside down as they looked for things to steal.
When the householder got back she found presents under the tree had been ripped open and taken in the living room.
Upstairs in her bedroom she found her underwear drawer had been emptied out in the search for things to steal.
Some envelopes written and sealed down by her daughter for Christmas had also been ripped open in the hope they could contain cash.
The intruders got away with a number of rings, a gold sovereign, worth together about £7,500, as well as three laptop computers.
Mr Meeke said, until it was recovered, one of the daughters feared she had lost two-and-a-half years of university work which was stored on one of the machines.
"Meanwhile a local tractor driver on Foxley Road, Sherston, was stopped by the driver of a silver Astra asking if he could provide some red diesel," he said.
"He said he couldn't provide any as it would be illegal and reported the matter to the police and gave details to them."
Soon after council workers alerted a police community support officer after seeing men selling jewellery in a car park in Malmesbury.
When the PCSO spoke to them they gave their names and said they had come on the train from Birmingham before walking off.
But when it was realised the break-in had taken place a search was launched and they were arrested walking towards Kemble after asking where the station was.
The Astra, which had false number plates on, was found nearby with the laptops in the boot but the jewellery was not recovered.
Rosindale and Nelson, both of Birmingham, pleaded guilty to burglary.
Chris Smyth, for Rosindale, said as a result of the offence his client had been recalled to prison on an earlier eight year sentence imposed for robbery and burglary.
As a result he said he was now not due for released until September 2017 and any new sentence would run alongside it.
Alex Daymond, for Nelson, said he was already a three strike burglar so must receive at least three years before getting a 20 per cent discount for pleading guilty.
Jailing them Judge Douglas Field said: "This was a serious case of dwelling house burglary. You had motored down here and picked this house.
"You kicked the door in and having gained entry there were untidy searches. Three laptops were taken and valuable jewellery of sentimental value taken. Christmas presents were ripped open and the like."
He jailed Rosindale for 20 months and Nelson for two years 146 days.
A third man, 20-year-old Luke Hales, also from Birmingham, is to face trial having pleaded not guilty to the charge.