even more review stuff

This commit is contained in:
steven-omaha
2023-01-31 16:42:16 +01:00
parent 71a977e60d
commit 8f4864c573
6 changed files with 114 additions and 4 deletions
+6
View File
@@ -1,6 +1,7 @@
use std::collections::HashSet;
use std::fs::read_to_string;
use std::path::PathBuf;
use std::process::ExitStatus;
use anyhow::{Context, Result};
use serde_json::Value;
@@ -17,6 +18,7 @@ const BINARY: Text = "cargo";
const SECTION: Text = "rust";
const SWITCHES_INSTALL: Switches = &["install"];
const SWITCHES_INFO: Switches = &["search", "--limit", "1"];
const SWITCHES_MAKE_DEPENDENCY: Switches = &[];
const SWITCHES_REMOVE: Switches = &["uninstall"];
impl Backend for Rust {
@@ -34,6 +36,10 @@ impl Backend for Rust {
self.get_all_installed_packages()
.context("getting all installed packages")
}
fn make_dependency(&self, packages: &[Package]) -> Result<ExitStatus> {
unreachable!()
}
}
fn extract_packages(json: Value) -> Result<HashSet<Package>> {