-
-
Notifications
You must be signed in to change notification settings - Fork 969
34 lines (26 loc) · 1.07 KB
/
lint-code.yml
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
name: Lint Code
on: [ push, pull_request ]
jobs:
lint:
runs-on: macos-14
if: always() && github.repository == 'LadybirdBrowser/ladybird'
steps:
- uses: actions/checkout@v4
- name: Set Up Environment
shell: bash
run: |
set -e
brew install curl flake8 llvm@18 ninja shellcheck swift-format unzip
# Note: gn isn't available in homebrew :(
# Corresponds to https://gn.googlesource.com/gn/+/225e90c5025bf74f41dbee60d9cde4512c846fe7
curl -L -o gn-mac-arm64.zip "https://chrome-infra-packages.appspot.com/dl/gn/gn/mac-arm64/+/786UV5-XW0Bz6QnRFxKtnzTSVq0ta5AU1KXRJs-ZNwcC"
unzip gn-mac-arm64.zip -d ${{ github.workspace }}/bin
chmod +x ${{ github.workspace }}/bin/gn
echo "${{ github.workspace }}/bin" >> $GITHUB_PATH
echo -n "gn version: "
${{ github.workspace}}/bin/gn --version
- name: Install JS Dependencies
shell: bash
run: npm install -g prettier@3.3.3
- name: Lint
run: ${{ github.workspace }}/Meta/lint-ci.sh