MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / ignore_rules

Method ignore_rules

atomic-repository/src/repository/changes.rs:102–108  ·  view source on GitHub ↗

Load ignore rules for this repository. This loads patterns from: - Global config: `~/.config/atomic/ignore` - Repository-local: `.atomicignore` in repository root The returned [`IgnoreRules`] can be used to check if paths should be ignored during tracking or status operations. # Example ```rust,ignore let repo = Repository::open(".")?; let rules = repo.ignore_rules(working_copy)?; if rules.is

(
        &self,
        working_copy: WorkingCopyId,
    )

Source from the content-addressed store, hash-verified

100 /// }
101 /// ```
102 pub fn ignore_rules(
103 &self,
104 working_copy: WorkingCopyId,
105 ) -> Result<IgnoreRules, RepositoryError> {
106 self.validate_working_copy(working_copy)?;
107 Ok(self.load_ignore_rules())
108 }
109
110 pub(super) fn load_ignore_rules(&self) -> IgnoreRules {
111 IgnoreRules::load(&self.root)

Callers 2

print_ignore_debugMethod · 0.45
is_ignoredMethod · 0.45

Calls 2

validate_working_copyMethod · 0.80
load_ignore_rulesMethod · 0.80

Tested by

no test coverage detected