A homeless man who stole less then £20 of items to feed a drug habit after he was evicted from a Mansfield flat invited the court to lock him up.
MIchael Severn was caught after taking chocolate and handcream from B&M Bargains and fragrances worth £13 from Primark, on August 20.
Prosecutor Sarah Sanderson said Severn also failed to comply with a community order on April 24, for shoplifting, when he tested positive for cocaine and heroin.
The court heard he would be recalled to prison.
Simon King, mitigating, said: "He obtained a tenancy but there were problems with arranging his rent and the landlord summarily evicted him.
"That led him back to taking drugs and his complete non-compliance.
"He invites the court to impose a custodial sentence. He need to get back on some sort of stability."
Severn, 27, admitted the thefts and the breach of the order, when he appeared at Mansfield Magistrates Court, on Wednesday.
District judge Jonathan Taaffe said: "It is refreshing to see someone who has reached rock bottom and is trying to sort it out."
He handed Severn 20 weeks in prison, and ordered him to pay a £122 government surcharge.
For more of the latest court cases from Mansfield Magistrates Court, click here.