musichoard/README.md
Wojciech Kozlowski 36b82049f2
All checks were successful
Cargo CI / Build and Test (push) Successful in 1m2s
Cargo CI / Lint (push) Successful in 42s
Cargo CI / Build and Test (pull_request) Successful in 2m26s
Cargo CI / Lint (pull_request) Successful in 44s
Add method to manually add artist metadata (#85)
Closes #55

Reviewed-on: #85
2024-01-10 22:33:57 +01:00

1.2 KiB

Music Hoard

Usage notes

Text selection

To select and copy text use the terminal-specific modifier key (on Linux this is usually the Shift key).

Code Coverage

Pre-requisites

rustup component add llvm-tools-preview
cargo install grcov

Generating Code Coverage

env CARGO_TARGET_DIR=codecov \
    cargo clean
env RUSTFLAGS="-C instrument-coverage" \
    LLVM_PROFILE_FILE="codecov/debug/profraw/musichoard-%p-%m.profraw" \
    CARGO_TARGET_DIR=codecov \
    BEETSDIR=./ \
    cargo test --all-features --all-targets
grcov codecov/debug/profraw \
      --binary-path ./codecov/debug/ \
      --output-types html \
      --source-dir . \
      --ignore-not-existing \
      --ignore "tests/*" \
      --ignore "src/main.rs" \
      --ignore "src/bin/mh-edit.rs" \
      --excl-start "GRCOV_EXCL_START|mod tests \{" \
      --excl-stop "GRCOV_EXCL_STOP" \
      --output-path ./codecov/debug/coverage/
xdg-open codecov/debug/coverage/index.html

Note that some changes may not be visible until codecov/debug/coverage is removed and the grcov command is rerun.

For most cases cargo clean can be replaced with rm -rf ./codecov/debug/{coverage,profraw}.