ANNAPOLIS, Md. - A man accused of killing five staffers at Maryland newspaper last year has pleaded guilty but not criminally responsible by reason of insanity.

Attorney Katy O'Donnell said Monday that Jarrod Ramos pleaded guilty to all 23 charges in the indictment, including five counts of first-degree murder.

Ramos is accused of killing employees of the Capital Gazette newspaper in Annapolis in 2018.

His plea means the case will skip the first phase of determining guilt and move to a second phase of determining whether he is criminally responsible.

The 39-year-old Ramos had originally pleaded not guilty and not criminally responsible. The latter term is Maryland's version of an insanity defence.

O'Donnell's remarks came during a pretrial hearing in Annapolis.