A$AP Rocky has reportedly been released from prison and is making his way back home.

Shortly after a judge ruled on Friday (Aug. 2) that Rocky and his two co-defendants in the Sweden assault case were free to leave the country until a verdict is reached on Aug. 14, Rocky bounced from the courtroom and used his Instagram account to share a message of gratitude.

"THANK YOU FROM THE BOTTOM OF MY HEART TO ALL OF MY FANS, FRIENDS AND ANYONE ACROSS THE GLOBE WHO SUPPORTED ME DURING THESE LAST FEW WEEKS," Rocky wrote on Instagram with a photo of himself. "I CANT BEGIN TO DESCRIBE HOW GRATEFUL I AM FOR ALL OF YOU THIS HAS BEEN A VERY DIFFICULT AND HUMBLING EXPERIENCE I WANT TO THANK THE COURT FOR ALLOWING ME BLADI AND THOTO TO RETURN TO OUR FAMILY AND FRIENDS THANKS AGAIN FOR ALL OF THE LOVE AND SUPPORT."

Rocky was spotted leaving the court in high spirits as the trial came to an end on Friday, with TMZ cameras capturing the moment. The site confirmed that Rocky was released from police custody at around 1:30 p.m. EST.

The trial has carried on over the course of three days with Rocky and his alleged victim, Mustafa Jafari, among the people who testified in the courtroom. Prosecutors attempted to argue that Rocky and his crew used bottles in the fight that went viral on July 1, while Rocky's team argued that they simply picked them up but did not use them to injure Jafari.

prosecution feels Rocky should be sentenced to six months

See 65 Hip-Hop Albums Turning 20 in 2019

More From XXL