Skip to content

feat(lsp): add Kotlin Language Server support#7

Merged
amondnet merged 4 commits into
mainfrom
6-featlsp-add-kotlin-language-server-support
Dec 17, 2025
Merged

feat(lsp): add Kotlin Language Server support#7
amondnet merged 4 commits into
mainfrom
6-featlsp-add-kotlin-language-server-support

Conversation

@amondnet

Copy link
Copy Markdown
Contributor

Summary

  • Add JetBrains Kotlin LSP support with auto-download capabilities
  • Platform detection for win-x64, linux-x64, linux-arm64, osx-x64, osx-arm64
  • Auto-download JRE 21 from vscode-java releases
  • Root detection via Gradle and Maven files

Changes

  • packages/lsp/src/server.ts: Added KotlinServer with auto-download logic
  • packages/lsp/src/index.ts: Exported KotlinServer
  • packages/lsp/src/__tests__/server.test.ts: Added KotlinServer tests
  • CLAUDE.md: Updated documentation

Test Plan

  • All 59 tests pass
  • TypeScript typecheck passes
  • ESLint passes
  • Manual test with Kotlin project

References

Closes #6

Add support for JetBrains Kotlin LSP with auto-download capabilities:

- Platform detection for win-x64, linux-x64, linux-arm64, osx-x64, osx-arm64
- Auto-download JetBrains Kotlin LSP (v0.253.10629)
- Auto-download bundled JRE 21 from vscode-java releases
- Root detection via Gradle (build.gradle.kts, build.gradle) and Maven (pom.xml)
- Support for .kt and .kts file extensions
- Exported KotlinServer from index.ts
- Added comprehensive tests for KotlinServer

Closes #6
@amondnet amondnet linked an issue Dec 17, 2025 that may be closed by this pull request
10 tasks
- Add Kotlin LSP to README supported languages table
- Create CLAUDE.md for packages/lsp with architecture overview
Error handling improvements:
- Replace empty .catch(() => {}) with proper error logging
- Add specific ENOENT checks instead of broad catch blocks
- Add try-catch around spawn() with error/exit event listeners
- Add user guidance message for dependency setup failures
- Add error context to verification failure messages

Documentation fixes:
- Fix misleading extractZip comment (system unzip, not Bun native)
- Update CLAUDE.md with accurate extension lists for all servers
- Add missing root detection files (go.sum, pyrightconfig.json, etc.)
- Update auto-download pattern example to match implementation

Test improvements:
- Add .kts extension test for getServersForExtension
@amondnet amondnet merged commit f71d8dd into main Dec 17, 2025
3 checks passed
@passionfactory-bot passionfactory-bot Bot mentioned this pull request Dec 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(lsp): add Kotlin Language Server support

1 participant