Skip to main content

CODE_ROOT_NAMES

Constant CODE_ROOT_NAMES 

Source
pub const CODE_ROOT_NAMES: &[&str];
Expand description

Home-relative directory names that conventionally hold a developer’s repositories.

Probed by name — existence is one stat each — when discovery has no registered repository to work outwards from. Deliberately a list of conventions rather than a walk of the home directory: ~ also contains Library, AppData and whatever a cloud-sync client has decided to materialise, and none of that is anybody’s code.

Documents/GitHub is GitHub Desktop’s default, source/repos is Visual Studio’s, and go/src is the layout every pre-modules Go install still has.