Retired Cardinal Roger Mahony was stripped of duties Thursday. NBC's Brian Williams reports.

The archdiocese of Los Angeles apologized Thursday night and stripped retired Cardinal Roger Mahony of all public duties for allegedly covering up years of child sexual abuse by Catholic priests.

In a move that came hours after the release of personnel files detailing years of alleged abuse by Los Angeles priests, Archbishop José H. Gomez announced Thursday night that Thomas Curry, Mahony's longtime top aide, was also resigning as regional bishop of Santa Barbara.

The files indicated that Mahony and other top archdiocese officials maneuvered behind the scenes for years to protect molester priests.

Mahony will "no longer have any administrative or public duties," Gomez said in a statement.

NBC 4 of Los Angeles reported that as Mahony's vicar for clergy, Curry assigned priests and deacons and was responsible for promoting "spiritual and physical well-being" for all priests and deacons in the archdiocese.

Mahony was head of the Los Angeles archdiocese from 1985 to 2011, when Gomez succeeded him.

"I find these files to be brutal and painful reading," Gomez wrote in a letter to parishioners. "The behavior described in these files is terribly sad and evil. There is no excuse, no explaining away what happened to these children."

NBC Los Angeles: An ex-Mahoney aide, Santa Barbara bishop resigns amid church abuse probe

"We need to acknowledge that terrible failure today," he wrote.

Read the full letter (.pdf)

Gomez said the church would "immediately report every credible allegation of abuse" and promised to support victims of priests' abuse.

Los Angeles Superior Court Judge Emilie Elias ordered release of the personnel files a week after internal church records revealed striking evidence of a coordinated campaign to shield priests accused of abuse.

The new files are especially damaging because they include the names of the accused priests, which the archdiocese — the largest Catholic diocese in the U.S. — had fought to protect.

Release of the files is expected to end years of legal battles over whether to identify the priests, the Los Angeles Times reported.

Related: