overrides.rs — tailwindcss Source File
Architecture documentation for overrides.rs, a rust file in the tailwindcss codebase. 3 imports, 0 dependents.
Entity Profile
Dependency Diagram
graph LR 052bdf49_a7ed_fe37_5862_bb70cea4527d["overrides.rs"] 9c36bab6_5718_da10_fc4d_44064df919d1["super::"] 052bdf49_a7ed_fe37_5862_bb70cea4527d --> 9c36bab6_5718_da10_fc4d_44064df919d1 2cad2c90_4399_255c_13ee_4577dbd9ac3a["std::path::Path"] 052bdf49_a7ed_fe37_5862_bb70cea4527d --> 2cad2c90_4399_255c_13ee_4577dbd9ac3a 9cbe6468_bd8d_8529_1ea5_0e68c0d2850e["crate::"] 052bdf49_a7ed_fe37_5862_bb70cea4527d --> 9cbe6468_bd8d_8529_1ea5_0e68c0d2850e style 052bdf49_a7ed_fe37_5862_bb70cea4527d fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
/*!
The overrides module provides a way to specify a set of override globs.
This provides functionality similar to `--include` or `--exclude` in command
line tools.
*/
use std::path::Path;
use crate::{
Error, Match,
gitignore::{self, Gitignore, GitignoreBuilder},
};
/// Glob represents a single glob in an override matcher.
///
/// This is used to report information about the highest precedent glob
/// that matched.
///
/// Note that not all matches necessarily correspond to a specific glob. For
/// example, if there are one or more whitelist globs and a file path doesn't
/// match any glob in the set, then the file path is considered to be ignored.
///
/// The lifetime `'a` refers to the lifetime of the matcher that produced
/// this glob.
#[derive(Clone, Debug)]
#[allow(dead_code)]
pub struct Glob<'a>(GlobInner<'a>);
#[derive(Clone, Debug)]
#[allow(dead_code)]
enum GlobInner<'a> {
/// No glob matched, but the file path should still be ignored.
UnmatchedIgnore,
/// A glob matched.
Matched(&'a gitignore::Glob),
}
impl<'a> Glob<'a> {
fn unmatched() -> Glob<'a> {
Glob(GlobInner::UnmatchedIgnore)
}
}
/// Manages a set of overrides provided explicitly by the end user.
#[derive(Clone, Debug)]
pub struct Override(Gitignore);
impl Override {
/// Returns an empty matcher that never matches any file path.
pub fn empty() -> Override {
Override(Gitignore::empty())
}
/// Returns the directory of this override set.
///
/// All matches are done relative to this path.
pub fn path(&self) -> &Path {
self.0.path()
}
// ... (230 more lines)
Domain
Subdomains
Functions
Dependencies
- crate::
- std::path::Path
- super::
Source
Frequently Asked Questions
What does overrides.rs do?
overrides.rs is a source file in the tailwindcss codebase, written in rust. It belongs to the OxideEngine domain, Scanner subdomain.
What functions are defined in overrides.rs?
overrides.rs defines 20 function(s): absolute_path, add, allow_directories, allow_unclosed_class, build, case_insensitive, default_case_sensitive, empty, gitignore, is_empty, and 10 more.
What does overrides.rs depend on?
overrides.rs imports 3 module(s): crate::, std::path::Path, super::.
Where is overrides.rs in the architecture?
overrides.rs is located at crates/ignore/src/overrides.rs (domain: OxideEngine, subdomain: Scanner, directory: crates/ignore/src).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free