Donate to the American Red Cross to help Hurricane Michael victims

Rapper Meek Mill granted bail

Meek Mill performs during V-103 Live Pop Up Concert at Philips Arena on March 25, 2017 in Atlanta, Georgia. (Photo by Rick Diamond/Getty Images)

Meek Mill will soon leave prison.

After spending nearly five months in jail following a controversial November ruling, the Philadelphia rapper, who received a sentence of two to four years in prison for violating probation, was granted bail on Tuesday by the Pennsylvania Supreme Court.

“I’d like to thank God, my family, my friends, my attorneys, my team at Roc Nation including JAY-Z, Desiree Perez, my good friend Michael Rubin, my fans, The Pennsylvania Supreme Court and all my public advocates for their love, support and encouragement during this difficult time,” the rapper, whose full name is Robert Rihmeek Williams, said in a statement obtained by CNN. “While the past five months have been a nightmare, the prayers, visits, calls, letters and rallies have helped me stay positive. To the Philadelphia District Attorney’s office, I’m grateful for your commitment to justice — not only for my case, but for others that have been wrongfully jailed due to police misconduct.”

Mill received a two-to-four year prison sentence in November for violating probation on a 2008 gun and drug case. (He was arrested after being involved in a fight and arrested again for popping wheelies on a dirt bike.) Judge Genece Brinkley cited a failed drug test and the rapper’s noncompliance with a court order restricting his travel in her sentencing order.

Earlier this month, the Philadelphia district attorney’s office recommended a new trial for Mill. But after a judge denied Mill bail, his plea was moved to the state’s Supreme Court.

The case has sparked outrage from criminal justice reform activists. Mill received widespread support from notable artists and athletes, including Colin Kapernick, rappers T.I. and Rick Ross, New England Patirots owner Robert Kraft, comedian Kevin Hart and Philadelphia 76ers co-owner Michael Rubin.

Rubin told CNN he hopes to pick up Mill from prison on Tuesday evening.

By Deena Zaru, CNN