Home / Function/ same_file_system() — tailwindcss Function Reference

same_file_system() — tailwindcss Function Reference

Architecture documentation for the same_file_system() function in walk.rs from the tailwindcss codebase.

Function rust RustCore PreProcessors calls 9 called by 1

Entity Profile

Dependency Diagram

graph TD
  95b107ae_d4d2_5303_7db9_2b4373c1db2e["same_file_system()"]
  bfa1582b_bd38_a7d2_556a_c51b8b6d647f["same_file_system()"]
  bfa1582b_bd38_a7d2_556a_c51b8b6d647f -->|calls| 95b107ae_d4d2_5303_7db9_2b4373c1db2e
  bfa1582b_bd38_a7d2_556a_c51b8b6d647f["same_file_system()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| bfa1582b_bd38_a7d2_556a_c51b8b6d647f
  e8c725dd_a885_9529_0af1_4e4171753fc6["tmpdir()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| e8c725dd_a885_9529_0af1_4e4171753fc6
  16c75919_5b4a_5654_6957_956f83d8171d["device_num()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| 16c75919_5b4a_5654_6957_956f83d8171d
  a870695d_932a_bfd4_fe92_a94ee09973bb["mkdirp()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| a870695d_932a_bfd4_fe92_a94ee09973bb
  61920b42_0d50_707e_d25e_adc8a3b7c42c["symlink()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| 61920b42_0d50_707e_d25e_adc8a3b7c42c
  c656cca4_0ca6_ad7c_4938_d8068064817a["follow_links()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| c656cca4_0ca6_ad7c_4938_d8068064817a
  5fe9aa4d_d793_b1a2_d187_4991d92c8d6e["assert_paths()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| 5fe9aa4d_d793_b1a2_d187_4991d92c8d6e
  375b58d9_a2fe_75bb_3a9f_2f5574c0532f["is_dir()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| 375b58d9_a2fe_75bb_3a9f_2f5574c0532f
  006bb599_d40b_f53b_44c7_57dfd4237729["path()"]
  95b107ae_d4d2_5303_7db9_2b4373c1db2e -->|calls| 006bb599_d40b_f53b_44c7_57dfd4237729
  style 95b107ae_d4d2_5303_7db9_2b4373c1db2e fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

crates/ignore/src/walk.rs lines 2414–2440

    fn same_file_system() {
        use super::device_num;

        // If for some reason /sys doesn't exist or isn't a directory, just
        // skip this test.
        if !Path::new("/sys").is_dir() {
            return;
        }

        // If our test directory actually isn't a different volume from /sys,
        // then this test is meaningless and we shouldn't run it.
        let td = tmpdir();
        if device_num(td.path()).unwrap() == device_num("/sys").unwrap() {
            return;
        }

        mkdirp(td.path().join("same_file"));
        symlink("/sys", td.path().join("same_file").join("alink"));

        // Create a symlink to sys and enable following symlinks. If the
        // same_file_system option doesn't work, then this probably will hit a
        // permission error. Otherwise, it should just skip over the symlink
        // completely.
        let mut builder = WalkBuilder::new(td.path());
        builder.follow_links(true).same_file_system(true);
        assert_paths(td.path(), &builder, &["same_file", "same_file/alink"]);
    }

Domain

Subdomains

Called By

Frequently Asked Questions

What does same_file_system() do?
same_file_system() is a function in the tailwindcss codebase.
What does same_file_system() call?
same_file_system() calls 9 function(s): assert_paths, device_num, follow_links, is_dir, mkdirp, path, same_file_system, symlink, and 1 more.
What calls same_file_system()?
same_file_system() is called by 1 function(s): same_file_system.

Analyze Your Own Codebase

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

Try Supermodel Free