diff options
Diffstat (limited to 'cli/lsp')
-rw-r--r-- | cli/lsp/analysis.rs | 2 | ||||
-rw-r--r-- | cli/lsp/cache.rs | 4 | ||||
-rw-r--r-- | cli/lsp/diagnostics.rs | 2 | ||||
-rw-r--r-- | cli/lsp/documents.rs | 2 | ||||
-rw-r--r-- | cli/lsp/language_server.rs | 11 | ||||
-rw-r--r-- | cli/lsp/testing/execution.rs | 8 | ||||
-rw-r--r-- | cli/lsp/tsc.rs | 2 |
7 files changed, 15 insertions, 16 deletions
diff --git a/cli/lsp/analysis.rs b/cli/lsp/analysis.rs index 8e9b4ccaa..250886283 100644 --- a/cli/lsp/analysis.rs +++ b/cli/lsp/analysis.rs @@ -5,7 +5,7 @@ use super::documents::Documents; use super::language_server; use super::tsc; -use crate::config_file::LintConfig; +use crate::args::LintConfig; use crate::tools::lint::create_linter; use crate::tools::lint::get_configured_rules; diff --git a/cli/lsp/cache.rs b/cli/lsp/cache.rs index 249177a64..0f7608278 100644 --- a/cli/lsp/cache.rs +++ b/cli/lsp/cache.rs @@ -1,8 +1,8 @@ // Copyright 2018-2022 the Deno authors. All rights reserved. MIT license. +use crate::args::ConfigFile; +use crate::args::Flags; use crate::cache::FetchCacher; -use crate::config_file::ConfigFile; -use crate::flags::Flags; use crate::graph_util::graph_valid; use crate::http_cache; use crate::proc_state::ProcState; diff --git a/cli/lsp/diagnostics.rs b/cli/lsp/diagnostics.rs index fe3b5ee45..52ba1ba96 100644 --- a/cli/lsp/diagnostics.rs +++ b/cli/lsp/diagnostics.rs @@ -13,7 +13,7 @@ use super::performance::Performance; use super::tsc; use super::tsc::TsServer; -use crate::config_file::LintConfig; +use crate::args::LintConfig; use crate::diagnostics; use deno_ast::MediaType; diff --git a/cli/lsp/documents.rs b/cli/lsp/documents.rs index ec1e183ae..4cc0beb2a 100644 --- a/cli/lsp/documents.rs +++ b/cli/lsp/documents.rs @@ -5,7 +5,7 @@ use super::text::LineIndex; use super::tsc; use super::tsc::AssetDocument; -use crate::config_file::ConfigFile; +use crate::args::ConfigFile; use crate::file_fetcher::get_source_from_bytes; use crate::file_fetcher::map_content_type; use crate::file_fetcher::SUPPORTED_SCHEMES; diff --git a/cli/lsp/language_server.rs b/cli/lsp/language_server.rs index 30a2ce253..4a703c719 100644 --- a/cli/lsp/language_server.rs +++ b/cli/lsp/language_server.rs @@ -54,10 +54,10 @@ use super::tsc::Assets; use super::tsc::AssetsSnapshot; use super::tsc::TsServer; use super::urls; -use crate::config_file::ConfigFile; -use crate::config_file::FmtConfig; -use crate::config_file::LintConfig; -use crate::config_file::TsConfig; +use crate::args::ConfigFile; +use crate::args::FmtConfig; +use crate::args::LintConfig; +use crate::args::TsConfig; use crate::deno_dir; use crate::file_fetcher::get_source_from_data_url; use crate::fs_util; @@ -364,8 +364,7 @@ impl Inner { if let Some(root_uri) = &self.config.root_uri { let root_path = fs_util::specifier_to_file_path(root_uri)?; let mut checked = std::collections::HashSet::new(); - let maybe_config = - crate::config_file::discover_from(&root_path, &mut checked)?; + let maybe_config = crate::args::discover_from(&root_path, &mut checked)?; Ok(maybe_config.map(|c| { lsp_log!(" Auto-resolved configuration file: \"{}\"", c.specifier); c diff --git a/cli/lsp/testing/execution.rs b/cli/lsp/testing/execution.rs index 03fdba63c..6b4e947a0 100644 --- a/cli/lsp/testing/execution.rs +++ b/cli/lsp/testing/execution.rs @@ -4,10 +4,11 @@ use super::definitions::TestDefinition; use super::definitions::TestDefinitions; use super::lsp_custom; +use crate::args::flags_from_vec; +use crate::args::DenoSubcommand; use crate::checksum; use crate::create_main_worker; use crate::emit; -use crate::flags; use crate::located_script_name; use crate::lsp::client::Client; use crate::lsp::client::TestingNotification; @@ -306,8 +307,7 @@ impl TestRun { ) -> Result<(), AnyError> { let args = self.get_args(); lsp_log!("Executing test run with arguments: {}", args.join(" ")); - let flags = - flags::flags_from_vec(args.into_iter().map(String::from).collect())?; + let flags = flags_from_vec(args.into_iter().map(String::from).collect())?; let ps = proc_state::ProcState::build(Arc::new(flags)).await?; let permissions = Permissions::from_options(&ps.flags.permissions_options()); @@ -327,7 +327,7 @@ impl TestRun { let sender = TestEventSender::new(sender); let (concurrent_jobs, fail_fast) = - if let flags::DenoSubcommand::Test(test_flags) = &ps.flags.subcommand { + if let DenoSubcommand::Test(test_flags) = &ps.flags.subcommand { ( test_flags.concurrent_jobs.into(), test_flags.fail_fast.map(|count| count.into()), diff --git a/cli/lsp/tsc.rs b/cli/lsp/tsc.rs index 76e428b2f..9988a0ac9 100644 --- a/cli/lsp/tsc.rs +++ b/cli/lsp/tsc.rs @@ -17,7 +17,7 @@ use super::text::LineIndex; use super::urls::LspUrlMap; use super::urls::INVALID_SPECIFIER; -use crate::config_file::TsConfig; +use crate::args::TsConfig; use crate::fs_util::specifier_to_file_path; use crate::tsc; use crate::tsc::ResolveArgs; |