IndexStoreDB

与 sourcekit-lsp 一起使用的索引数据库库。『Index database library for use with sourcekit-lsp』

  • 所有者: swiftlang/indexstore-db
  • 平台: Linux,Mac,Windows Subsystem for Linux (WSL)
  • 許可證: Apache License 2.0
  • 分類:
  • 主題:
  • 喜歡:
    0
      比較:

Github星跟蹤圖

IndexStoreDB

IndexStoreDB is a source code indexing library. It provides a composable and efficient query API for looking up source code symbols, symbol occurrences, and relations. IndexStoreDB uses the libIndexStore library, which lives in swiftlang/llvm-project, for reading raw index data. Raw index data can be produced by compilers such as Apple Clang and Swift using the -index-store-path option. IndexStoreDB enables efficiently querying this data by maintaining acceleration tables in a key-value database built with LMDB.

IndexStoreDB's data model is derived from libIndexStore. For more information about libIndexStore, and producing raw indexing data, see the Indexing While Building whitepaper.

Building IndexStoreDB

IndexStoreDB is built using the Swift Package Manager.

For a standard debug build and test:

$ swift build
$ swift test

Building on Linux

The C++ code in the index requires libdispatch, but unlike Swift code, it cannot find it automatically on Linux. You can work around this by adding a search path manually.

$ swift build -Xcxx -I<path_to_swift_toolchain>/usr/lib/swift -Xcxx -I<path_to_swift_toolchain>/usr/lib/swift/Block

Some Example Users

Pecker: a tool to detect unused code based on SwiftSyntax and IndexStoreDB.

Contributing to Swift

Contributions to indexstore-db are welcomed and encouraged! Please see the
Contributing to Swift guide.

Before submitting the pull request, please make sure you have tested your
changes

and that they follow the Swift project guidelines for contributing
code
.

To be a truly great community, Swift.org needs to welcome
developers from all walks of life, with different backgrounds, and with a wide
range of experience. A diverse and friendly community will have more great
ideas, more unique perspectives, and produce more great code. We will work
diligently to make the Swift community welcoming to everyone.

To give clarity of what is expected of our members, Swift has adopted the
code of conduct defined by the Contributor Covenant. This document is used
across many open source communities, and we think it articulates our values
well. For more, see the Code of Conduct.

Development

For more information about developing IndexStoreDB, see Development.

主要指標

概覽
名稱與所有者swiftlang/indexstore-db
主編程語言C++
編程語言Swift (語言數: 7)
平台
許可證Apache License 2.0
所有者活动
創建於2018-10-26 03:42:22
推送於2025-06-13 12:29:42
最后一次提交
發布數1683
最新版本名稱swift-DEVELOPMENT-SNAPSHOT-2025-06-12-a (發布於 2025-06-13 04:03:29)
第一版名稱swift-DEVELOPMENT-SNAPSHOT-2019-02-14-a (發布於 2019-02-15 13:04:09)
用户参与
星數351
關注者數120
派生數79
提交數440
已啟用問題?
問題數8
打開的問題數6
拉請求數224
打開的拉請求數3
關閉的拉請求數14
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?