File: main.yml

package info (click to toggle)
profanity 0.15.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,028 kB
  • sloc: ansic: 78,627; makefile: 543; python: 212; sh: 132
file content (60 lines) | stat: -rw-r--r-- 1,694 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: CI

on:
  push:
    branches: [master]
  pull_request:
    branches: [master]

concurrency:
  group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
  cancel-in-progress: true

jobs:
  linux:
    runs-on: ubuntu-latest

    strategy:
      matrix:
        flavor: [arch, debian, fedora, ubuntu]

    name: Linux
    steps:
      - uses: actions/checkout@v2
      - name: Run tests
        run: |
          docker build -f Dockerfile.${{ matrix.flavor }} -t profanity .
          docker run profanity ./ci-build.sh

  code-style:
    runs-on: ubuntu-22.04
    name: Check coding style
    continue-on-error: true
    steps:
      - uses: actions/checkout@v2
      # if this check fails, you have to update the number of auto types known and the list of auto types in the check below
      - name: Check auto types are up-to-date
        run: |
          [[ "$(find src -type f -name '*.[ch]' -exec awk '/^#define auto_[\W]*/ {print $2}' '{}' \; | sort -u | wc -l)" == "8" ]] || exit -1
      - name: Check auto types are initialized
        run: |
          grep -P 'auto_(char|gchar|gcharv|guchar|jid|sqlite|gfd|FILE)[\w *]*;$' -r src && exit -1 || true
      - name: Run clang-format
        uses: jidicula/clang-format-action@v4.11.0
        with:
          clang-format-version: '16'
          check-path: 'src'

  spell-check:
    runs-on: ubuntu-22.04
    name: Check spelling
    continue-on-error: true
    steps:
      - uses: actions/checkout@v2
      - name: install dependencies
        run: |
          sudo apt update
          sudo apt install -y --no-install-recommends codespell
      - name: Check spelling
        run: |
          codespell