worktree-io 0.17.6

A CLI tool to open GitHub issues as git worktree workspaces
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use worktree_io::opener::available_entries::available_entries;

pub(super) fn detect_all_editors() -> Vec<(&'static str, &'static str)> {
    available_entries()
        .into_iter()
        .map(|e| (e.display, e.command))
        .collect()
}

#[cfg(test)]
mod tests {
    use super::*;
    #[test]
    fn test_detect_all_editors_returns_vec() {
        let editors = detect_all_editors();
        assert!(editors.iter().any(|&(name, _)| name == "Terminal"));
    }
}