Former FBI Director James Comey has dropped a legal challenge to a Republican-led effort to compel his testimony before Congress, which is seeking more information about the bureau's investigations in the run up to the 2016 elections.

As part of a new agreement with the Republican-led House Judiciary Committee, lawmakers have agreed to release a full transcript of Comey's testimony within 24 hours, and he in turn is free to make all or part of it available to the public, his lawyer, David Kelley, told Reuters.

Comey tweet

Last week, Comey filed a motion Washington, D.C. federal court to discard the subpoena from Judiciary Committee Chairman Bob Goodlatte, R-Va. Comey's request that the closed-door deposition be put on hold infuriated Goodlatte, who accused the former director of seeking "special treatment"

Goodlatte tweet

His lawyers had argued that the legal action was intended "to prevent the Joint Committee from using the pretext of a closed interview to peddle a distorted, partisan political narrative about the Clinton and Russian investigations through selective leaks." The Judiciary Committee's legal team dismissed that argument, and in a filing branded Comey's effort "extraordinary and frivolous."

Goodlatte originally subpoenaed Comey on Nov. 21 to testify in a closed-door setting. Loretta Lynch, who served as attorney general under former President Barack Obama, was also subpoenaed by the committee to testify Dec. 4.

Republicans have blistered Comey ever since he declined to recommend criminal charges against former Secretary of State Hillary Clinton for using a private server to conduct government business. Investigators had determined that emails found on the server contained classified information had been sent.

--Reuters contributed to this article.

WATCH: The Trump-Russia ties hiding in plain sight