Skip to content

fix: Fixed css parsing case #21

fix: Fixed css parsing case

fix: Fixed css parsing case #21

Workflow file for this run

name: Release Rust Project
on:
push:
tags:
- "v*.*.*"
jobs:
build:
name: Build for ${{ matrix.target }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
short: linux
bin_suffix: ""
- os: macos-latest
target: x86_64-apple-darwin
short: macos
bin_suffix: ""
- os: windows-latest
target: x86_64-pc-windows-msvc
short: win
bin_suffix: ".exe"
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- name: Build binary
run: cargo build --release --target ${{ matrix.target }}
- name: Rename binary
run: |
mkdir -p artifacts
cp target/${{ matrix.target }}/release/css-linter${{ matrix.bin_suffix }} artifacts/css-linter-${{ matrix.short }}${{ matrix.bin_suffix }}
shell: bash
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: css-linter-${{ matrix.short }}${{ matrix.bin_suffix }}
path: artifacts/
release:
name: Create Release
needs: build
runs-on: ubuntu-latest
steps:
- name: Download all artifacts
uses: actions/download-artifact@v4
with:
path: artifacts
- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
files: artifacts/**/*
env:
GITHUB_TOKEN: ${{ secrets.TOKEN }}