Skip to content

adding kraken2 scripts to linux binaries #67

adding kraken2 scripts to linux binaries

adding kraken2 scripts to linux binaries #67

Workflow file for this run

name: Rust Coverage
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
coverage:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
ref: ${{ github.head_ref }}
- name: Install Rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: true
- name: Install cargo-tarpaulin
run: cargo install cargo-tarpaulin
- name: Run coverage
run: cargo +nightly tarpaulin --out Xml
- name: Upload coverage to GitHub Actions
uses: actions/upload-artifact@v2
with:
name: coverage
path: cobertura.xml
- name: Update README badge
run: |
coverage_percent=$(grep -oP 'line-rate="\K[^"]*' cobertura.xml | head -n 1)
coverage_percent=$(printf "%.2f" $(echo "$coverage_percent * 100" | bc -l))
sed -i "s|coverage-\([0-9]*\(\.[0-9]*\)\?\)%25-brightgreen|coverage-${coverage_percent}%25-brightgreen|g" README.md
git config --global user.name 'GitHub Actions'
git config --global user.email 'actions@users.noreply.github.com'
git add README.md
git commit -m "Update coverage badge [skip ci]" || true
git push || true