Skip to content

Commit

Permalink
Projects are now sorted by type
Browse files Browse the repository at this point in the history
  • Loading branch information
Bdeering1 committed Jun 23, 2023
1 parent d132916 commit 17ce583
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ fn main() {
return;
}

projects.sort_by_key(|p| p.project_type);

if !args.dry_run {
menu::project_menu(projects, args.verbose);
}
Expand Down
8 changes: 4 additions & 4 deletions src/project.rs
Original file line number Diff line number Diff line change
Expand Up @@ -90,15 +90,15 @@ impl Project {
}
}

#[derive(Debug)]
#[derive(Debug, Copy, Clone, Ord, Eq, PartialOrd, PartialEq)]
pub enum ProjectType {
Node,
Cargo,
Mix,
Composer,
Dotnet,
Gradle,
Composer,
Misc,
Mix,
Node,
}

impl Display for ProjectType {
Expand Down

0 comments on commit 17ce583

Please sign in to comment.