Explore tree-sitter based structured editing

Đang mở
#25 3 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 1 ngày

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

Đánh giá

Độ khó
5/5
Thời gian dự kiến
Hơn một tuần
Mức phù hợp với người mới
20/100
Loại issue
Tính năng
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Đình trệ
Công nghệ
go
Lĩnh vực
devtools

Hướng nghiên cứu

Start by reading the existing tree-sitter parsing and dependency graph code, then inspect how Stacklit builds and exposes stacklit.json. The issue proposes several possible editing approaches and leaves key design questions open, with no files or tests identified. Done means defining a concrete scope and deciding how node edits and cross-file updates should work.

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

Mô tả

enhancement feature help wanted

From discussion #19 by @yunfan.

Stacklit already parses codebases with tree-sitter and builds dependency graphs. The next logical step is using those same parsed trees for structured code editing, locating a node by its tree-sitter path and replacing it with generated code.

What this could look like:

  • Target a specific function/type/export by its tree-sitter path
  • Replace or patch that node while preserving surrounding code
  • Use stacklit's dependency graph to find cross-file call sites that need updating

Open questions:

  • Tree-sitter gives syntax, not semantics. Cross-file renames need the dependency layer too.
  • How to handle edits that change the tree structure (adding params, changing return types)
  • Could work as a separate companion tool that reads stacklit.json for the graph

No timeline. Scoping for now.

Ngôn ngữ chính
Go
Star
114
Fork
9
Merge trung bình
19 giờ 38 phút
Pull request đã merge (30 ngày)
30

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

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 glincker/stacklit

Tất cả issue của glincker/stacklit

Issue tương tự

Thêm issue về Go

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.