mirror of
https://github.com/elicpeter/nyx.git
synced 2026-06-09 19:45:13 +02:00
docs: Enhance module documentation across various files for clarity a… (#62)
* docs: Enhance module documentation across various files for clarity and completeness * fix: Remove unnecessary blank line in build.rs for cleaner code * docs: Update documentation to improve clarity and consistency in code comments
This commit is contained in:
parent
40995e45e7
commit
1f2bfe76c1
44 changed files with 721 additions and 366 deletions
|
|
@ -713,6 +713,22 @@ fn builtin_profile(name: &str) -> Option<ScanProfile> {
|
|||
})
|
||||
}
|
||||
|
||||
/// Top-level scanner configuration.
|
||||
///
|
||||
/// Loaded from `nyx.conf` (TOML) via [`Config::load`], or constructed in
|
||||
/// code for embedded use. [`Config::default`] gives conservative defaults:
|
||||
/// no symlink following, no hidden files, gitignore respected, 10 s parse
|
||||
/// timeout, all analysis passes on.
|
||||
///
|
||||
/// Config sections mirror `nyx.conf` sections:
|
||||
/// - [`scanner`](Config::scanner): what files to scan, which analysis passes
|
||||
/// to enable, severity floor
|
||||
/// - [`output`](Config::output): format, ranking, LOW-finding budgets
|
||||
/// - [`analysis`](Config::analysis): per-language rules, engine-pass toggles
|
||||
/// - [`performance`](Config::performance): thread count, depth limit, batch
|
||||
/// size
|
||||
/// - [`database`](Config::database): incremental index settings
|
||||
/// - [`detectors`](Config::detectors): per-detector sensitivity knobs
|
||||
#[derive(Debug, Serialize, Deserialize, Clone)]
|
||||
#[serde(default)]
|
||||
#[derive(Default)]
|
||||
|
|
|
|||
|
|
@ -1,3 +1,16 @@
|
|||
//! Shared utilities and configuration.
|
||||
//!
|
||||
//! Re-exports [`Config`], [`AnalysisOptions`], and [`DetectorOptions`] from
|
||||
//! their submodules. [`Config`] is loaded from `nyx.conf` and passed through
|
||||
//! the top-level call stack. [`AnalysisOptions`] is installed once per process
|
||||
//! via an `OnceLock` and read back via [`analysis_options::current`] from deep
|
||||
//! inside the analysis pipeline without threading it through every call frame.
|
||||
//!
|
||||
//! Other submodules: `path` (root-relative path utilities and traversal guards),
|
||||
//! `project` (framework detection, project metadata), `query_cache` (cached
|
||||
//! tree-sitter query compilation), `snippet` (source snippet extraction for
|
||||
//! finding locations).
|
||||
|
||||
pub mod analysis_options;
|
||||
pub mod config;
|
||||
pub mod detector_options;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue