Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Split remote.ts by topic, starting with migrations

Đang mở
#1,066 2 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 2 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
55/100
Loại issue
Tái cấu trúc
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Ít trao đổi
Công nghệ
typescript
Lĩnh vực
devtools

Hướng nghiên cứu

Bắt đầu trong src/remote/remote.ts bằng cách đọc migrateLegacyAuthority, migrateToSecretsStorage, migrateSessionTokenFile và migrateSessionAuthFromFiles, cùng với các hàm gọi chúng trong setup và setupCoderRemote. Tách các phương thức đơn giản này vào src/remote/migrations.ts, đồng thời giữ nguyên hành vi, thời điểm xóa và việc truyền các span telemetry; luồng migration phải tiếp tục hoạt động không thay đổi.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Improvement tech-debt vs-code

`src/remote/remote.ts` is 1,207 lines and mixes every concern of remote setup in one class. Recent work (per-editor SSH configs, legacy authority migration) keeps growing it.

Topics currently mixed into the class

  • Setup orchestration: `setup`, `setupCoderRemote`
  • Migrations: `migrateLegacyAuthority` (authority), `migrateToSecretsStorage`, `migrateSessionTokenFile`, `migrateSessionAuthFromFiles` (credentials)
  • SSH config assembly: `updateSSHConfig`, `writeRemoteSshConfig`, `buildProxyCommand`, `getSshConfigPath`, `getLogArgs`, `getLogDir`
  • Workspace lifecycle: `lookupWorkspace`, `waitForWorkspaceReady`, `resolveAgent`
  • Auth/session: `ensureLoggedInAndRetry`, `showSessionExpiredDialog`, `watchRemoteSessionAuth`
  • Binary management: `resolveRemoteBinary`, `checkCompatibility`
  • Window/UI glue: `createAgentMetadataStatusBar`, `watchSettings`, `registerLabelFormatter`, `closeRemote`, `reloadWindow`

Proposal

  1. Extract migrations first, e.g. into `src/remote/migrations.ts`. They are self-contained, interact little with the rest of setup, and each has a deletion horizon; keeping them together makes them easy to find and eventually remove.
  2. If that lands well, extract SSH config assembly next. It is the most test-heavy area and only needs the path resolver, settings, and logger.
  3. Keep orchestration (`setup`/`setupCoderRemote`) in `remote.ts`.

Non-goals: no behavior changes and no new abstractions; move plain methods by topic and keep the telemetry span threading as is.

Filed by Claude Code for @EhabY.

Ngôn ngữ chính
TypeScript
Star
131
Fork
48
Merge trung bình
2 ngày 3 giờ
Pull request đã merge (30 ngày)
16

Chuẩn bị môi trường

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của coder/vscode-coder

Tất cả issue của coder/vscode-coder

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.