From ffe6aa08584b82f8a71cb7ce7d1d2ff793689c6f Mon Sep 17 00:00:00 2001 From: michal Date: Tue, 14 Jun 2022 21:16:22 +0100 Subject: [PATCH] fixed stuff ig --- Cargo.lock | 92 +------------------------------------- flake.nix | 4 ++ src/args.rs | 4 -- src/internal/initialise.rs | 4 +- 4 files changed, 7 insertions(+), 97 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 30cb60c..c96a708 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -7,30 +7,15 @@ name = "Amethyst" version = "3.1.0" dependencies = [ "clap", + "libc", "mimalloc", "native-tls", "regex", - "runas", "rusqlite", "serde", "ureq", ] -[[package]] -name = "addr2line" -version = "0.17.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9ecd88a8c8378ca913a680cd98f0f13ac67383d35993f86c90a70e3f137816b" -dependencies = [ - "gimli", -] - -[[package]] -name = "adler" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" - [[package]] name = "ahash" version = "0.7.6" @@ -59,21 +44,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" -[[package]] -name = "backtrace" -version = "0.3.64" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e121dee8023ce33ab248d9ce1493df03c3b38a659b240096fcbd7048ff9c31f" -dependencies = [ - "addr2line", - "cc", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", -] - [[package]] name = "base64" version = "0.13.0" @@ -160,15 +130,6 @@ version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" -[[package]] -name = "failure" -version = "0.1.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d32e9bd16cc02eae7db7ef620b392808b89f6a5e16bb3497d159c6b92a0f4f86" -dependencies = [ - "backtrace", -] - [[package]] name = "fallible-iterator" version = "0.2.0" @@ -226,12 +187,6 @@ dependencies = [ "wasi", ] -[[package]] -name = "gimli" -version = "0.26.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78cc372d058dcf6d5ecd98510e7fbc9e5aec4d21de70f65fea8fecebcd881bd4" - [[package]] name = "hashbrown" version = "0.11.2" @@ -362,16 +317,6 @@ dependencies = [ "libmimalloc-sys", ] -[[package]] -name = "miniz_oxide" -version = "0.4.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a92518e98c078586bc6c934028adcca4c92a53d6a958196de835170a01d84e4b" -dependencies = [ - "adler", - "autocfg", -] - [[package]] name = "native-tls" version = "0.2.10" @@ -390,15 +335,6 @@ dependencies = [ "tempfile", ] -[[package]] -name = "object" -version = "0.27.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67ac1d3f9a1d3616fd9a60c8d74296f22406a238b6a72f5cc1e6f314df4ffbf9" -dependencies = [ - "memchr", -] - [[package]] name = "once_cell" version = "1.10.0" @@ -531,16 +467,6 @@ dependencies = [ "winapi", ] -[[package]] -name = "runas" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a620b0994a180cdfa25c0439e6d58c0628272571501880d626ffff58e96a0799" -dependencies = [ - "cc", - "which", -] - [[package]] name = "rusqlite" version = "0.26.3" @@ -556,12 +482,6 @@ dependencies = [ "smallvec", ] -[[package]] -name = "rustc-demangle" -version = "0.1.21" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef03e0a2b150c7a90d01faf6254c9c48a41e95fb2a8c2ac1c6f0d2b9aefc342" - [[package]] name = "ryu" version = "1.0.9" @@ -779,16 +699,6 @@ version = "0.10.2+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fd6fbd9a79829dd1ad0cc20627bf1ed606756a7f77edff7b66b7064f9cb327c6" -[[package]] -name = "which" -version = "3.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d011071ae14a2f6671d0b74080ae0cd8ebf3a6f8c9589a2cd45f23126fe29724" -dependencies = [ - "failure", - "libc", -] - [[package]] name = "winapi" version = "0.3.9" diff --git a/flake.nix b/flake.nix index a46f943..293d992 100644 --- a/flake.nix +++ b/flake.nix @@ -35,7 +35,11 @@ rustc cargo rustfmt + cargo-audit clippy + openssl + sqlite + pkg-config ]; }; }); diff --git a/src/args.rs b/src/args.rs index 6c3d1a3..a2815cd 100644 --- a/src/args.rs +++ b/src/args.rs @@ -18,11 +18,7 @@ pub struct Args { #[derive(Debug, Clone, Subcommand)] pub enum Operation { /// Installs a package from either the AUR or the PacMan-defined repositories -<<<<<<< HEAD - #[clap(name="install", aliases=&["i", "ins", "-S"])] -======= #[clap(name="install", aliases=&["ins", "in", "i", "-S"])] ->>>>>>> 89ce64b91730d93806b58605d8fd03a21c2f5bfd Install(InstallArgs), /// Removes a previously installed package diff --git a/src/internal/initialise.rs b/src/internal/initialise.rs index e249037..200f14a 100644 --- a/src/internal/initialise.rs +++ b/src/internal/initialise.rs @@ -97,7 +97,7 @@ pub fn init(options: Options) { "Couldn't set permissions for path: {}/.cache/ame: {}", homedir, e ), - 4, + AppExitCode::FailedCreatingPaths, ); } }; @@ -121,7 +121,7 @@ pub fn init(options: Options) { "Couldn't set permissions for path: {}/.local/share/ame: {}", homedir, e ), - 4, + AppExitCode::FailedCreatingPaths, ); } };