reloaded-project/Build Optimized Rust Binary

Builds a min sized Rust binary or library. With self-built std, abort on panic, PGO and cross-compilation support.

View on GitHub

Trust Signals

Scorecard Score
not yet scored
Maintenance Recency
Stale
License
None
namedescriptionrequireddefault
rust-project-pathPath to the Rust projectno.
workspace-pathPath to the workspace root. Defaults to rust-project-path if not specified.no""
build-libraryBuild a library instead of a binary. Requires `crate-type = ["cdylib", "staticlib"]` in Cargo.toml.nofalse
crate-nameName of the Rust crate/package. Used for cache key and artifact directory. Legacy: also used for artifact naming if artifact-prefix not set (deprecated).no""
targetThe target platform for the Rust compileryes
featuresComma-separated list of features to include in the buildno""
run-tests-and-coverageRun tests and coverage using the `devops-rust-test-and-coverage` action.nofalse
use-cacheEnable or disable the build cache using Swatinem/rust-cache.notrue
no-default-featuresDo not include default features in the buildnofalse
rust-toolchainThe Rust toolchain to use for building. Can be nightly or a specific nightly version (nightly-2025-09-18). Note: stable and beta are not supported due to required nightly features.nonightly
use-crossUse cross-rs for building. If false, use cargo.nofalse
use-pgoUse Profile-Guided Optimization [PGO] to build the artifact.nofalse
pgo-project-pathPath to the Rust project used for gathering PGO data. Can be same or separate project.no.
pgo-benchmark-nameBenchmark name to use with PGO.nomy_benchmark
abort-on-panicAbort immediately on panic. If false, the default panic handler is used.notrue
size-optimized-stdEnable size optimization for std by adding `optimize_for_size` to build-std-features.nofalse
upload-artifactsUpload the built artifacts as a GitHub Actions artifactnotrue
upload-symbols-separatelyUpload debug symbol files (.pdb, .dwp, .dSYM) as separate artifacts instead of bundling with main artifactsnotrue
use-friendly-target-namesTransform target triples to user-friendly names (e.g., x86_64-unknown-linux-gnu -> linux-x64) in artifact namesnotrue
artifact-prefixPrefix for artifact names. Combined with target/features to form final artifact name (e.g., 'MyApp' -> 'MyApp-linux-x64'). If empty, no prefix is used.no""
artifact-name-exclude-featuresComma-separated list of features to exclude from artifact names. Set to empty string to include all.noc-exports,bench,nightly
additional-rustflagsAdditional RUSTFLAGS to pass to the Rust compilerno""
additional-rustc-argsAdditional arguments to pass directly to rustcno""
additional-std-featuresAdditional build-std features to include (comma-separated).no""
upload-coverage-to-codecovUploads coverage to codecov if `run-tests-and-coverage` is enabled.notrue
codecov-tokenCodecov token for uploading coverageno
use-tarpaulinUse tarpaulin for code coverage. If false, code coverage will be disabled.notrue
use-binstallWhether to use cargo-binstall in the test-and-coverage action for installing tools like tarpaulin. This parameter is passed through to the devops-rust-test-and-coverage action.notrue
install-binstallWhether to install cargo-binstall to make it available for the test-and-coverage action. If false, assumes it is already available in the environment.notrue
additional-test-argsAdditional arguments passed directly to the cargo test command (e.g., '--ignored --test-threads=1 --lib')no""
additional-tarpaulin-argsAdditional arguments to pass to the cargo tarpaulin commandno""
packagesPackages to test (multi-line list). Passed through to devops-rust-test-and-coverage. Selects packages for testing; does not influence the build.no""
codecov-flagsFlags to pass to Codecov for organizing coverage reportsnounittests
codecov-nameCustom defined name for the coverage uploadnocodecov-umbrella

no outputs