internal: prepare to use standard .run pattern for subcommands
This commit is contained in:
parent
0d2b423f40
commit
e8a67b67bf
3 changed files with 5 additions and 4 deletions
|
|
@ -1,7 +1,6 @@
|
|||
//! Driver for rust-analyzer.
|
||||
//!
|
||||
//! Based on cli flags, either spawns an LSP server, or runs a batch analysis
|
||||
mod flags;
|
||||
mod logger;
|
||||
mod rustc_wrapper;
|
||||
|
||||
|
|
@ -10,7 +9,7 @@ use std::{convert::TryFrom, env, fs, path::Path, process};
|
|||
use lsp_server::Connection;
|
||||
use project_model::ProjectManifest;
|
||||
use rust_analyzer::{
|
||||
cli::{self, AnalysisStatsCmd},
|
||||
cli::{self, flags, AnalysisStatsCmd},
|
||||
config::Config,
|
||||
from_json,
|
||||
lsp_ext::supports_utf8,
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
//! Various batch processing tasks, intended primarily for debugging.
|
||||
|
||||
pub mod flags;
|
||||
pub mod load_cargo;
|
||||
mod analysis_stats;
|
||||
mod diagnostics;
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
use std::path::PathBuf;
|
||||
|
||||
use ide_ssr::{SsrPattern, SsrRule};
|
||||
use rust_analyzer::cli::Verbosity;
|
||||
|
||||
use crate::cli::Verbosity;
|
||||
|
||||
xflags::xflags! {
|
||||
src "./src/bin/flags.rs"
|
||||
|
|
@ -196,7 +197,7 @@ impl RustAnalyzer {
|
|||
// generated end
|
||||
|
||||
impl RustAnalyzer {
|
||||
pub(crate) fn verbosity(&self) -> Verbosity {
|
||||
pub fn verbosity(&self) -> Verbosity {
|
||||
if self.quiet {
|
||||
return Verbosity::Quiet;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue