Persist index for /rustdoc
in LMDB (#12988)
This PR updates the `/rustdoc` command with persistence for the documented rustdoc items. Now when you run `/rustdoc --index <CRATE_NAME>` it will index the crate and store the results in LMDB. The documented items will then be read from the database when searching using `/rustdoc` and persist across restarts of Zed. Release Notes: - N/A
This commit is contained in:
parent
6c70a809ec
commit
85acc2be44
5 changed files with 174 additions and 38 deletions
|
@ -1,8 +1,12 @@
|
|||
use std::sync::Arc;
|
||||
|
||||
use serde::{Deserialize, Serialize};
|
||||
use strum::EnumIter;
|
||||
|
||||
#[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Hash, Clone, Copy, EnumIter)]
|
||||
#[derive(
|
||||
Debug, PartialEq, Eq, PartialOrd, Ord, Hash, Clone, Copy, Serialize, Deserialize, EnumIter,
|
||||
)]
|
||||
#[serde(rename_all = "snake_case")]
|
||||
pub enum RustdocItemKind {
|
||||
Mod,
|
||||
Macro,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue