SEATTLE — Oregon’s highest court cleared the way on Thursday for the release of thousands of pages of documents detailing accusations and investigations of sexual abuse or other improprieties by Boy Scout leaders around the nation from the mid-1960s into the 1980s.

The files played a central role in a civil case in 2010 over the abuse of six boys by a scout leader in Portland, Ore., in the 1980s. That trial ended with an $18.5 million punitive judgment against the Boy Scouts of America, the largest ever by far against the organization in a sex case jury trial.

The “perversion files,” which the Boy Scout organization said were kept as a way of weeding out bad leaders and preventing abuse, instead became evidence in the trial. And the state judge in the case, John A. Wittmayer, ruled that as evidence, the files should be released to the public under the open records provision of the Oregon Constitution, but with the names of possible victims and people who had reported accusations redacted. Thursday’s ruling by the Oregon Supreme Court rejected an appeal by the Boy Scouts of America, and said the judge had not exceeded his authority.

“Oregon’s framers sought to require the courts to conduct the business of administering justice in public — that is, in a manner that permits scrutiny of the court’s work,” the court said in its unanimous 31-page ruling.