Skip to content

Commit e7ffe6e

Browse files
prilrazheregelya
authored andcommitted
ci: add lint-cloudlinux GitHub Action
The cloudlinux fork uses the cloudlinux branch as trunk; the inherited upstream workflows (unit-tests.yml, codespell.yml, etc.) only fire on master so they never run for PRs into this fork. Add a narrow workflow that runs on every push and PR targeting cloudlinux and invokes `make lint-non-ascii` to gate against stray non-ASCII bytes in Python source. Calling the make target keeps a single source of truth: local `make lint` runs the same check via the same script, so what passes locally is exactly what passes in CI. Resurrecting the full upstream test+lint matrix on this fork is a separate, larger task.
1 parent cb7efd8 commit e7ffe6e

1 file changed

Lines changed: 36 additions & 0 deletions

File tree

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Lint (cloudlinux)
2+
3+
# CloudLinux fork uses the `cloudlinux` branch as trunk; the inherited
4+
# upstream workflows (unit-tests.yml, codespell.yml, etc.) only fire on
5+
# `master` and so do not run on this fork. This narrow workflow guards
6+
# the cloudlinux branch against the most common regression we have hit:
7+
# stray non-ASCII bytes in Python source (em-dashes, smart quotes,
8+
# ellipsis from copy/paste, leftover BOMs).
9+
#
10+
# The check is just `make lint-non-ascii`, which delegates to
11+
# utils/check-non-ascii.py. That same target is also invoked as a
12+
# prerequisite of `make lint`, so local developers get the identical
13+
# rule when they run the full lint locally.
14+
#
15+
# Broader fixes (running the full upstream test+lint matrix on cloudlinux
16+
# PRs) are tracked separately.
17+
18+
on:
19+
pull_request:
20+
branches: [cloudlinux]
21+
push:
22+
branches: [cloudlinux]
23+
24+
permissions:
25+
contents: read
26+
27+
jobs:
28+
lint-non-ascii:
29+
name: Reject undeclared non-ASCII in Python source
30+
runs-on: ubuntu-latest
31+
steps:
32+
- name: Checkout
33+
uses: actions/checkout@v4
34+
35+
- name: make lint-non-ascii
36+
run: make lint-non-ascii

0 commit comments

Comments
 (0)