A gunman who pointed a loaded revolver at a Syrian man and his friends has been jailed for five years.
William Harvey, 28, pointed the weapon at Said Shekhe and five others who were helping him to move furniture.
The High Court in Edinburgh heard that all the men were from Syria and were in fear for their lives as the handgun was trained on each of them in turn.
Police later found the weapon, which contained one live round, hidden in a beam at Harvey's Glasgow home.
Harvey had earlier admitted illegal possession of the firearm and ammunition, having the gun with intent to cause victims to believe that violence would be used against them and behaving in a threatening or abusive manner on 22 November last year.
Mr Shekhe and the other Syrian men, who were all in their 20s, were unloading furniture when Harvey initially approached them and began shouting aggressively.
They could not understand what he was saying and thought he was under the influence of drink or drugs.
Harvey returned several times to shout at them and at one stage kicked the door of a parked car and climbed onto another and kicked the bonnet and roof before reappearing with the gun.
Harvey, who has previous convictions for violence, disorder and drugs with offences containing racial, religious and sexual aggravations, was detained at his home by police after armed response officers were called in. His DNA was found on the gun.
Defence solicitor advocate Kate Phillips said Harvey had been the victim of serious violence in the past and witnessed the murder of his best friend.
She said: "He literally became a recluse and was living in fear of further attempts on his life."
But she said Harvey had made positive changes in his life with the help of a partner following an earlier prison sentence.
However, an aunt, who was like a second mother to him, had died, followed by the death of his mother.
Ms Phillips said: "This had a devastating impact on him. He was extremely close to his mother and quite simply he went off the rails when she died."
She said Harvey had started taking drugs again and at the time of the offence had been drinking and consuming crack cocaine.
"He fully appreciates and understands the fear and alarm he caused to these men and he appreciates how terrifying it must have been for them," she said.
She added that he was "deeply ashamed" of his behaviour and told the court: "He is only 28 and he is absolutely determined to turn his life around."
Judge Lady Rae told Harvey he had "effectively threatened wholly innocent people who must have been absolutely terrified" and said his conduct merited "a very significant sentence".
She told Harvey he clearly had a very tragic background with a number of tragedies happening in his life, but added that none of that excused what he had done.
She pointed out that the firearms offence carried a minimum sentence of five years' imprisonment.