I'm pretty sure it's fundamentally the same, no?

Search upward and add anything that is `.chef`. I could add the `directory?` check, but the actual existence check is done later at line ~45.