diff --git a/Cargo.toml b/Cargo.toml index e3e9788..3782f71 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -6,17 +6,12 @@ autobins = true [features] default = [] -algorithms = [] - -[[bin]] -name = "sha256sum" -path = "src/bin/sha256sum.rs" -required-features = [] +all-algorithms = [] [[bin]] name = "picca" path = "src/bin/picca.rs" -required-features = ["algorithms"] +required-features = ["all-algorithms"] [dependencies] sha2 = "0.10.9" diff --git a/Justfile b/Justfile index 8e0192f..de41be4 100644 --- a/Justfile +++ b/Justfile @@ -14,10 +14,12 @@ default: build-docker build-release doc # main build build-release: cargo build --release + cargo build --release --bin picca --features all-algorithms # debug build build-debug: cargo build + cargo build --bin picca --features all-algorithms # build docker images locally build-docker: clean diff --git a/docker/Dockerfile b/docker/Dockerfile index a07ce05..8d407ee 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -6,7 +6,7 @@ WORKDIR /usr/src/picca COPY . . RUN apk upgrade --no-cache && apk add musl-dev -RUN cargo install --path . && cargo clean +RUN cargo install --path . --bin picca --features all-algorithms && cargo clean FROM alpine:3 AS package diff --git a/src/lib.rs b/src/lib.rs index 17624d6..109e49e 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -82,7 +82,7 @@ pub struct Args { )] pub debug: bool, - #[cfg(feature = "algorithms")] + #[cfg(feature = "all-algorithms")] #[arg( short, long,