Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clean up workflow names (steps / jobs) #1149

Merged
merged 3 commits into from
Nov 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .github/workflows/cli.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,19 +21,19 @@ jobs:
matrix:
os:
[ubuntu-latest-16-cores, macos-latest-xlarge, windows-latest-16-cores]
name: 🚦 Test
name: ${{ matrix.os }}
runs-on: ${{ matrix.os }}

steps:
- name: 🛑 Cancel Previous Runs
- name: Cancel Previous Runs
uses: styfle/[email protected]

- run: git config --global core.autocrlf false

- name: ⬇️ Checkout qlty
- name: Checkout qlty
uses: actions/checkout@v4

- name: 🦀 Install Rust toolchain
- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
Expand All @@ -45,10 +45,10 @@ jobs:
uses: shivammathur/setup-php@v2
if: matrix.os == 'macos-latest-xlarge'

- name: 🫙 Cache Rust
- name: Cache Rust
uses: Swatinem/rust-cache@v2

- name: 🚦 Run Test
- name: Run Test
run: cargo llvm-cov --lcov --output-path target/lcov.info -- --include-ignored

- uses: qltysh/qlty-action/coverage@main
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/cli_integration.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Integration Tests
name: Integration Tests (Ruby)
on:
workflow_dispatch:
push:
Expand All @@ -24,31 +24,31 @@ env:

jobs:
build:
name: 🏗️ Build Release CLI
name: Build Release CLI
runs-on: ubuntu-latest
steps:
- name: ⬇️ Checkout cloud
- name: Checkout cloud
uses: actions/checkout@v4

- name: 🦀 Install Rust toolchain
- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable

- name: 🫙 Cache Rust
- name: Cache Rust
uses: Swatinem/rust-cache@v2

- name: 🏗️ Build Release CLI
- name: Build Release CLI
run: cargo build --release

- name: 📦 Archive CLI
- name: Archive CLI
uses: actions/upload-artifact@v4
with:
name: qlty
path: target/release/qlty

test_ruby_binary_install:
name: "🧪 Test: Ruby Binary Install"
name: ${{ matrix.container }}
runs-on: ubuntu-latest
needs: build
strategy:
Expand Down Expand Up @@ -97,13 +97,13 @@ jobs:
git add .
git commit -m "Initial commit"

- name: 📦 Download CLI
- name: Download CLI
uses: actions/download-artifact@v4
with:
name: qlty
path: ${{ github.workspace }}/bin

- name: "🚦 Run Test"
- name: Run Test
run: |
export PATH=$GITHUB_WORKSPACE/bin:$PATH
chmod +x $GITHUB_WORKSPACE/bin/qlty
Expand Down
25 changes: 12 additions & 13 deletions .github/workflows/plugins.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,62 +22,61 @@ jobs:
matrix:
os:
[macos-latest-xlarge, ubuntu-latest-16-cores, windows-latest-16-cores]
name: Plugins test on ${{ matrix.os }}
name: ${{ matrix.os }}
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash

steps:
- name: 🛑 Cancel Previous Runs
- name: Cancel Previous Runs
uses: styfle/[email protected]

- name: ⬇️ Checkout repo
- name: Checkout repo
uses: actions/checkout@v4

- name: 📦 Use Node.js
- name: Use Node.js
uses: actions/setup-node@v4
with:
cache: "npm"
cache-dependency-path: plugins/package-lock.json

# Generate Cache key for Linux/macOS
- name: 🔒 Set CACHE_MONTH on Linux/macOS
- name: Generate cache key
run: echo "CACHE_MONTH=$(date +'%Y-%m')" >> $GITHUB_ENV

- name: 💾 Cache qlty tools
- name: Cache qlty tools
uses: actions/cache@v3
with:
path: ~/.qlty
key: ${{ runner.os }}-qlty-${{ env.CACHE_MONTH }}

- name: 📦 Setup PHP with PECL extension
- name: Setup PHP with PECL extension
uses: shivammathur/setup-php@v2
if: matrix.os == 'macos-latest-xlarge'

- name: 📦 Setup Ruby
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.3.0
if: matrix.os == 'windows-latest-16-cores'

- name: 🦀 Install Rust toolchain
- name: Install Rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable

- name: 🫙 Cache Rust
- name: Cache Rust
uses: Swatinem/rust-cache@v2

- name: ⚙️ cargo build
- name: cargo build
run: cargo build
env:
RUST_BACKTRACE: 1

- name: Move qlty into PATH
run: echo "${{ github.workspace }}/target/debug" >> $GITHUB_PATH

- name: 🔍 Check qlty version
- name: Check qlty version
run: qlty --version

# Login to the GitHub Container Registry to reduce trivy rate limiting errors
Expand Down
Loading