From 0e1f7ae61f48e4d9b6cfbef9a8fde544f669e08d Mon Sep 17 00:00:00 2001 From: Christian Kessler Date: Thu, 25 Apr 2024 14:34:13 -0700 Subject: [PATCH] Update super-linter.yml Signed-off-by: Christian Kessler --- .github/workflows/super-linter.yml | 60 ++++++++++++++++++------------ 1 file changed, 37 insertions(+), 23 deletions(-) diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml index ca69cec8..143cca42 100644 --- a/.github/workflows/super-linter.yml +++ b/.github/workflows/super-linter.yml @@ -1,29 +1,43 @@ -# This workflow executes several linters on changed files based on languages used in your code base whenever -# you push a code or open a pull request. -# -# You can adjust the behavior by modifying this file. -# For more information, see: -# https://github.com/github/super-linter -name: Lint Code Base +name: Check Set-Up & Build +# Controls when the action will run. on: + # Triggers the workflow on push or pull request events but only for the master branch push: - branches: [ "main" ] + branches: [main] pull_request: - branches: [ "main" ] + branches: [main] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: - run-lint: - runs-on: ubuntu-latest + check: + # The type of runner that the job will run on + runs-on: ubuntu-22.04 + + # Steps represent a sequence of tasks that will be executed as part of the job steps: - - name: Checkout code - uses: actions/checkout@v3 - with: - # Full git history is needed to get a proper list of changed files within `super-linter` - fetch-depth: 0 - - - name: Lint Code Base - uses: github/super-linter@v4 - env: - VALIDATE_ALL_CODEBASE: false - DEFAULT_BRANCH: "main" - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v3 + + - name: Install linux dependencies + run: sudo apt-get install -y clang libssl-dev llvm libudev-dev protobuf-compiler + + - name: Install Rust + run: | + rustup update stable --no-self-update + rustup target add wasm32-unknown-unknown + + # Rust cache + - uses: Swatinem/rust-cache@v2 + + - name: Check Build + run: | + SKIP_WASM_BUILD=1 cargo check --release + + - name: Check Build for Benchmarking + run: > + pushd node && + cargo check --features=runtime-benchmarks --release