diff --git a/packages/core/src/v1/config/lsp.ts b/packages/core/src/v1/config/lsp.ts index d17866f4113..c4a05e6d55c 100644 --- a/packages/core/src/v1/config/lsp.ts +++ b/packages/core/src/v1/config/lsp.ts @@ -4,7 +4,7 @@ import { Schema } from "effect" export const Disabled = Schema.Struct({ disabled: Schema.Literal(true), -}).pipe((schema) => schema) +}) export const Entry = Schema.Union([ Disabled, @@ -15,7 +15,7 @@ export const Entry = Schema.Union([ env: Schema.optional(Schema.Record(Schema.String, Schema.String)), initialization: Schema.optional(Schema.Record(Schema.String, Schema.Unknown)), }), -]).pipe((schema) => schema) +]) // Keep this list aligned with the builtin servers in opencode's LSP runtime. // Custom servers must declare extensions because the runtime cannot infer them. @@ -73,8 +73,8 @@ export const requiresExtensionsForCustomServers = Schema.makeFilter< return ok ? undefined : "For custom LSP servers, 'extensions' array is required." }) -export const Info = Schema.Union([Schema.Boolean, Schema.Record(Schema.String, Entry)]) - .check(requiresExtensionsForCustomServers) - .pipe((schema) => schema) +export const Info = Schema.Union([Schema.Boolean, Schema.Record(Schema.String, Entry)]).check( + requiresExtensionsForCustomServers, +) export type Info = Schema.Schema.Type