A burglar who carried out a series of raids has been jailed for five years and eight months at Lincoln Crown Court.
James Webster targeted properties in Gainsborough and the nearby village of Morton earlier this year.
Jeremy Janes, prosecuting, said that Webster broke into the Lincolnshire Otter pub in Gainsborough in the early hours of April 16 while the landlord, landlady and their three children were asleep in the living quarters above the pub.
Webster set off the alarm and when the landlord went downstairs to investigate he found him in the kitchen holding a claw hammer.
Webster made off with £50 from the till but was arrested nearby.
Three days later Webster smashed a window to get into a house in Southlands Gardens, Morton, while the occupiers were in bed and stole a handbag and contents.
The same night he stole a handbag after breaking into a car in Morton and then went to Belvoir Close in the village where he attempted to break into another house.
Police were called and he was arrested after being found in Front Street, Morton.
The court was told that he had been dealt with by courts on seven previous occasions for either burglary or attempt burglary.
Webster, 39, of Salisbury Street, Gainsborough, admitted burglaries of a house at Southlands Gardens, Morton, and of the Lincolnshire Otter pub in Somerby Road, Gainsborough.
He admitted further attempt burglaries of houses in Belvoir Close, Morton; and Gainas Avenue, Gainsborough; together with the theft of a handbag and contents from a car parked in Morton.
He asked for a further offence of burglary at a solicitors’ office in Lord Street, Gainsborough, to be taken into consideration.
He also admitted a charge of threatening behaviour and two offences of shoplifting involving the theft of bottles of spirits from Morrisons on January 21 and the theft of a television from the Tesco store on March 25.
Judge Simon Hirst, passing sentence, told him: “You have a dreadful history of dishonesty. You have committed burglaries time after time after time.”
Mark Watson, in mitigation, said: “This is a man who has had his demons with drugs.”
He said that Webster emerged from his most recent prison sentence with the aim of staying off drugs and had been on a rehabilitation programme.
But the agency providing the service changed and the then began to miss appointments.
Mr Watson said: “As a result the prescription that had kept him from buying drugs on the street was stopped. He then found himself buying drugs off the streets and here we are.
“He was committing burglaries not only to fund the purchase of drugs but to pay for electricity and food.”