Home / Function/ stops_at_git_dir() — tailwindcss Function Reference

stops_at_git_dir() — tailwindcss Function Reference

Architecture documentation for the stops_at_git_dir() function in dir.rs from the tailwindcss codebase.

Entity Profile

Dependency Diagram

graph TD
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2["stops_at_git_dir()"]
  510a4ebc_9a2a_672a_2d6d_a56dabd1134b["dir.rs"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|defined in| 510a4ebc_9a2a_672a_2d6d_a56dabd1134b
  0b6611f3_9e1d_0a3b_157b_ef9bb2bc3d89["tmpdir()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| 0b6611f3_9e1d_0a3b_157b_ef9bb2bc3d89
  c80dd0da_2638_ff74_8c3d_7986668a41c5["mkdirp()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| c80dd0da_2638_ff74_8c3d_7986668a41c5
  195d465d_cb01_6c11_b964_d3f792d97f6f["path()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| 195d465d_cb01_6c11_b964_d3f792d97f6f
  fe4c91f2_5b95_b103_1edb_19b3ea6da080["wfile()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| fe4c91f2_5b95_b103_1edb_19b3ea6da080
  ea4007ac_a311_c454_45f6_4e3ba7192b1a["build()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| ea4007ac_a311_c454_45f6_4e3ba7192b1a
  5f1e446c_b1a6_cd2c_2707_77480f9eaad4["add_child()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| 5f1e446c_b1a6_cd2c_2707_77480f9eaad4
  df4238ce_ff67_ee56_17ce_54ac1d2fa297["matched()"]
  9baf307f_a3dc_b5b5_7e74_d809f64a89c2 -->|calls| df4238ce_ff67_ee56_17ce_54ac1d2fa297
  style 9baf307f_a3dc_b5b5_7e74_d809f64a89c2 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

crates/ignore/src/dir.rs lines 1156–1176

    fn stops_at_git_dir() {
        // This tests that .gitignore files beyond a .git barrier aren't
        // matched, but .ignore files are.
        let td = tmpdir();
        mkdirp(td.path().join(".git"));
        mkdirp(td.path().join("foo/.git"));
        wfile(td.path().join(".gitignore"), "foo");
        wfile(td.path().join(".ignore"), "bar");

        let ig0 = IgnoreBuilder::new().build();
        let (ig1, err) = ig0.add_child(td.path());
        assert!(err.is_none());
        let (ig2, err) = ig1.add_child(ig1.path().join("foo"));
        assert!(err.is_none());

        assert!(ig1.matched("foo", false).is_ignore());
        assert!(ig2.matched("foo", false).is_none());

        assert!(ig1.matched("bar", false).is_ignore());
        assert!(ig2.matched("bar", false).is_ignore());
    }

Domain

Subdomains

Frequently Asked Questions

What does stops_at_git_dir() do?
stops_at_git_dir() is a function in the tailwindcss codebase, defined in crates/ignore/src/dir.rs.
Where is stops_at_git_dir() defined?
stops_at_git_dir() is defined in crates/ignore/src/dir.rs at line 1156.
What does stops_at_git_dir() call?
stops_at_git_dir() calls 7 function(s): add_child, build, matched, mkdirp, path, tmpdir, wfile.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free