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

Method is_ignored

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

Check if a path should be ignored. This is a convenience method that loads ignore rules and checks the path. If you need to check multiple paths, use [`Self::ignore_rules`] instead to avoid reloading the rules for each check. # Arguments `path` - Path to check (relative to repository root) `is_dir` - Whether the path is a directory # Returns `true` if the path should be ignored, `false` other

(
        &self,
        working_copy: WorkingCopyId,
        path: &Path,
        is_dir: bool,
    )

Source from the content-addressed store, hash-verified

126 ///
127 /// `true` if the path should be ignored, `false` otherwise.
128 pub fn is_ignored(
129 &self,
130 working_copy: WorkingCopyId,
131 path: &Path,
132 is_dir: bool,
133 ) -> Result<bool, RepositoryError> {
134 Ok(self.ignore_rules(working_copy)?.is_ignored(path, is_dir))
135 }
136
137 /// Save a change to the repository.
138 ///

Callers 4

walkMethod · 0.45
query_viewMethod · 0.45
should_ignore_with_rulesFunction · 0.45

Calls 1

ignore_rulesMethod · 0.45

Tested by

no test coverage detected