Updated

Former NFL star Aaron Hernandez spent nearly two years in a Massachusetts prison involved in fights and receiving dozens of infractions before he hanged himself in his cell last month, disciplinary records revealed.

Hernandez, whose conviction in a 2013 murder was erased on Tuesday, received 78 disciplinary offenses in 12 incidents while he was at Souza-Baranowski Correction Center, USA Today reported. Most of them took place within the first three months he was there.

In May 2015, he allegedly received 25 of the violations within eight days, shortly after he was found guilty of murdering semi-pro football player Odin Lloyd.

AARON HERNANDEZ'S MURDER CONVICTION ERASED

The former New England Patriots star was involved in three fights and served as a lookout at the prison for a period of time. In his first fight, Hernandez reportedly told officers that prison wasn't for him.

"This place ain’t [expletive] to me,” Hernandez told officers. “I’ll run this place and keep running [expletive]. Prison ain't [expletive] to me."

In another incident, Hernandez attacked an inmate for trying to shake his hand, according to USA Today.

"Hernandez struck [name redacted] with a closed fist to the face and both men engage [sic] in a physical altercation,” according to the incident report. "The combatants ignored several direct orders to cease their actions and chemical agent was utilized to separate the inmates."

Hernandez and the inmate were placed in segregation after the incident.

On Dec. 3, 2015, corrections officers found a knife-shaped piece of metal that was wrapped with a cloth at one end and attached to a tether. It was his ninth incident of the year.

INSIDE THE MIND OF AARON HERNANDEZ

The last few months of Hernandez's time in prison, he continued to commit offenses. He was involved in three more incidents before he hanged himself using a bedsheet.

Corrections officers found Hernandez in the his jail cell shortly after 3 a.m. on April 19. He was rushed to the hospital where he was pronounced dead.

The words "John 3:16" were written on his forehead and wall, Fox 25 Boston reported. A Bible was also left open to the verse that read: "For God so loved the world that he gave his only Son, that whoever believes in Him shall not perish but have eternal life." Three notes were later discovered in the cell, two of which were addressed to his fiancee Shayanna Jenkins and their 4-year-old daughter.

His suicide came five days after a jury acquitted him in the 2012 shooting deaths of two men. On Tuesday, a judge erased his conviction in the 2013 murder of Odin Lloyd because Hernandez died before the repeal was heard.

Hernandez's appellate attorneys made their request under a long-standing legal principle holding that when defendants die before their direct appeal is decided, their convictions are vacated. Prosecutors argued that dismissing Hernandez’s murder conviction would reward his decision to take his own life.

"Despite the tragic ending to Aaron Hernandez's life, he should not reap the legal benefits of an antiquated rule," Bristol County District Attorney Thomas M. Quinn III said in a statement.

The district attorney plans to file an appeal.