Skip to content

Commit

Permalink
Add max depth when analyzing the workspace
Browse files Browse the repository at this point in the history
  • Loading branch information
pfoerster committed May 21, 2019
1 parent a44697a commit 0011d1c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ impl<C: LspClient + Send + Sync> LatexLspServer<C> {
pub async fn initialize(&self, params: InitializeParams) -> Result<InitializeResult> {
if let Some(Ok(path)) = params.root_uri.map(|x| x.to_file_path()) {
for entry in WalkDir::new(path)
.min_depth(1)
.max_depth(4)
.into_iter()
.filter_map(|e| e.ok())
.filter(|x| x.file_type().is_file())
Expand Down

0 comments on commit 0011d1c

Please sign in to comment.