diff --git a/.github/workflows/build.yml b/.github/workflows/lint-build.yml similarity index 50% rename from .github/workflows/build.yml rename to .github/workflows/lint-build.yml index a78956e..35d95cb 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/lint-build.yml @@ -8,6 +8,26 @@ on: workflow_call: jobs: + lint-markdown: + runs-on: ubuntu-latest + steps: + - name: Check out repository + uses: actions/checkout@v4 + + - name: Lint markdown files + uses: avto-dev/markdown-lint@v1.5.0 + with: + args: "**/*.md" + + lint-yaml: + runs-on: ubuntu-latest + steps: + - name: Check out repository + uses: actions/checkout@v4 + + - name: Lint yaml files + uses: ibiqlik/action-yamllint@v3.1.1 + build: runs-on: ubuntu-latest steps: @@ -27,4 +47,7 @@ jobs: run: cargo test - name: Cargo build - run: cargo build + run: cargo build --release + + - name: Create and lint debian package + run: ./debian-build.sh --lint diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml deleted file mode 100644 index adb66cb..0000000 --- a/.github/workflows/lint.yml +++ /dev/null @@ -1,30 +0,0 @@ -name: Lint - -on: - pull_request: - branches: [main] - push: - branches: [main] - - workflow_call: - -jobs: - lint-markdown: - runs-on: ubuntu-latest - steps: - - name: Check out repository - uses: actions/checkout@v4 - - - name: Lint markdown files - uses: avto-dev/markdown-lint@v1.5.0 - with: - args: "**/*.md" - - lint-yaml: - runs-on: ubuntu-latest - steps: - - name: Check out repository - uses: actions/checkout@v4 - - - name: Lint yaml files - uses: ibiqlik/action-yamllint@v3.1.1 diff --git a/README.md b/README.md index 2b425d3..0bb1a76 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ ![Rust](https://img.shields.io/badge/Rust-000000?logo=rust&logoColor=white) ![Debian](https://img.shields.io/badge/Debian-A81D33?logo=debian&logoColor=white) ![GitHub Release Status](https://img.shields.io/github/actions/workflow/status/ad2ien/caps-lock-auto-switch/release.yml?label=release&logo=github&branch=main) -![GitHub Build Status](https://img.shields.io/github/actions/workflow/status/ad2ien/caps-lock-auto-switch/build.yml?label=build&logo=github&branch=main) +![GitHub Build Lint Status](https://img.shields.io/github/actions/workflow/status/ad2ien/caps-lock-auto-switch/lint-build.yml?label=build&logo=github&branch=main) ![License](https://img.shields.io/badge/license-GPL%202%2B%202.0-blue.svg) ![Gitmoji](https://img.shields.io/badge/gitmoji-%20%F0%9F%98%9C%20%F0%9F%98%8D-FFDD67.svg)