Update amplitude metadata #526
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
pull_request: | |
branches: | |
- 'main' | |
name: continuous-integration-main | |
jobs: | |
ci: | |
strategy: | |
max-parallel: 1 | |
matrix: | |
os: [ ubuntu-latest, macos-latest ] | |
runs-on: ${{ matrix.os }} | |
env: | |
RUST_BACKTRACE: full | |
# Make sure CI fails on all warnings, including Clippy lints | |
RUSTFLAGS: "-Dwarnings" | |
steps: | |
- name: Freeing up more disk space | |
run: | | |
sudo rm -rf /usr/local/lib/android # will release about 10 GB if you don't need Android | |
sudo rm -rf /usr/share/dotnet # will release about 20GB if you don't need .NET | |
sudo rm -rf /opt/ghc | |
sudo rm -rf /usr/local/share/boost | |
sudo rm -rf /opt/hostedtoolcache/CodeQL | |
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | |
- uses: actions/checkout@v2 | |
- name: Install package (ubuntu-latest) | |
if: matrix.os == 'ubuntu-latest' | |
run: | | |
sudo docker image prune --all --force | |
echo 'APT::Get::Always-Include-Phased-Updates "false";' | sudo tee /etc/apt/apt.conf.d/99-phased-updates | |
sudo apt-get update && sudo apt-get upgrade -y | |
sudo apt-get install -y protobuf-compiler libprotobuf-dev | |
- name: Install package (macos-latest) | |
if: matrix.os == 'macos-latest' | |
run: | | |
brew install protobuf | |
- name: Setup Rust toolchain | |
# Call `rustup show` as a hack so that the toolchain defined in rust-toolchain.toml is installed | |
run: rustup show | |
- name: Use Cache | |
uses: Swatinem/rust-cache@v2 | |
with: | |
cache-on-failure: true | |
key: "${{ matrix.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}" | |
shared-key: "shared" | |
- name: Install Protoc | |
uses: arduino/setup-protoc@v1 | |
with: | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
- name: Build | |
uses: actions-rs/cargo@v1 | |
with: | |
command: build | |
args: --all-features | |
- name: Test | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --all --all-features | |
- name: Rustfmt | |
uses: actions-rs/cargo@v1 | |
with: | |
command: fmt | |
args: --all -- --check | |
- name: Clippy -- Main | |
uses: actions-rs/cargo@v1 | |
with: | |
command: clippy | |
args: --all-features -- -W clippy::all -A clippy::style -A clippy::forget_copy -A clippy::forget_ref | |
- name: Clippy -- All Targets | |
uses: actions-rs/cargo@v1 | |
with: | |
command: clippy | |
# We are a bit more forgiving when it comes to the code in tests and only check for correctness | |
args: --all-features --all-targets -- -A clippy::all -W clippy::correctness -A clippy::forget_copy -A clippy::forget_ref |