In any action or proceeding to enforce a provision of sections
1981,
1981a,
1982,
1983,
1985, and
1986 of this title, title IX of Public Law 92–318 [
20 U.S.C.
1681 et seq.], the Religious Freedom Restoration Act of 1993 [
42 U.S.C.
2000bb et seq.], the Religious Land Use and Institutionalized Persons Act of 2000 [
42 U.S.C.
2000cc et seq.], title VI of the Civil Rights Act of 1964 [
42 U.S.C.
2000d et seq.], or section
13981 of this title, the court, in its discretion, may allow the prevailing party, other than the United States, a reasonable attorney’s fee as part of the costs, except that in any action brought against a judicial officer for an act or omission taken in such officer’s judicial capacity such officer shall not be held liable for any costs, including attorney’s fees, unless such action was clearly in excess of such officer’s jurisdiction.