mirror of
https://github.com/vlang/v.git
synced 2025-08-04 02:07:28 -04:00
ci: add a linter for the .yml workflow files (#21459)
This commit is contained in:
parent
c8004fc905
commit
c21f7f0b90
3
.github/.prettierrc
vendored
Normal file
3
.github/.prettierrc
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"singleQuote": true
|
||||||
|
}
|
2
.github/ISSUE_TEMPLATE/documentation.yml
vendored
2
.github/ISSUE_TEMPLATE/documentation.yml
vendored
@ -1,7 +1,7 @@
|
|||||||
name: 📕 Documentation Issue
|
name: 📕 Documentation Issue
|
||||||
description: Report an issue in the Reference documentation or Developer Guide
|
description: Report an issue in the Reference documentation or Developer Guide
|
||||||
title: (short issue description)
|
title: (short issue description)
|
||||||
labels: "Unit: Documentation"
|
labels: ['Unit: Documentation']
|
||||||
body:
|
body:
|
||||||
- type: textarea
|
- type: textarea
|
||||||
id: description
|
id: description
|
||||||
|
6
.github/dependabot.yml
vendored
6
.github/dependabot.yml
vendored
@ -1,6 +1,6 @@
|
|||||||
version: 2
|
version: 2
|
||||||
updates:
|
updates:
|
||||||
- package-ecosystem: "github-actions"
|
- package-ecosystem: 'github-actions'
|
||||||
directory: "/"
|
directory: '/'
|
||||||
schedule:
|
schedule:
|
||||||
interval: "daily"
|
interval: 'daily'
|
||||||
|
1
.github/workflows/debug.yml
vendored
1
.github/workflows/debug.yml
vendored
@ -3,7 +3,6 @@ name: Debug CI
|
|||||||
on: [workflow_dispatch]
|
on: [workflow_dispatch]
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
debug-msvc:
|
debug-msvc:
|
||||||
runs-on: windows-2019
|
runs-on: windows-2019
|
||||||
timeout-minutes: 121
|
timeout-minutes: 121
|
||||||
|
10
.github/workflows/docs_ci.yml
vendored
10
.github/workflows/docs_ci.yml
vendored
@ -7,12 +7,12 @@ name: Docs CI
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.yml"
|
- '**.yml'
|
||||||
- "!**/docs_ci.yml"
|
- '!**/docs_ci.yml'
|
||||||
pull_request:
|
pull_request:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.yml"
|
- '**.yml'
|
||||||
- "!**/docs_ci.yml"
|
- '!**/docs_ci.yml'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.sha || github.ref }}
|
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.sha || github.ref }}
|
||||||
@ -45,7 +45,7 @@ jobs:
|
|||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
repository: vlang/v
|
repository: vlang/v
|
||||||
ref: master # important
|
ref: master # important
|
||||||
path: pv
|
path: pv
|
||||||
|
|
||||||
- name: Check against parent commit
|
- name: Check against parent commit
|
||||||
|
4
.github/workflows/paths_ci.yml
vendored
4
.github/workflows/paths_ci.yml
vendored
@ -3,11 +3,11 @@ name: Path Testing CI
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.md"
|
- '**.md'
|
||||||
- '!**/paths_ci.yml'
|
- '!**/paths_ci.yml'
|
||||||
pull_request:
|
pull_request:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.md"
|
- '**.md'
|
||||||
- '!**/paths_ci.yml'
|
- '!**/paths_ci.yml'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
|
86
.github/workflows/prebuilt.yml
vendored
86
.github/workflows/prebuilt.yml
vendored
@ -10,62 +10,62 @@ jobs:
|
|||||||
runs-on: ubuntu-20.04
|
runs-on: ubuntu-20.04
|
||||||
timeout-minutes: 5
|
timeout-minutes: 5
|
||||||
steps:
|
steps:
|
||||||
- name: Download V
|
- name: Download V
|
||||||
run: |
|
run: |
|
||||||
wget https://github.com/vlang/v/releases/latest/download/v_linux.zip
|
wget https://github.com/vlang/v/releases/latest/download/v_linux.zip
|
||||||
unzip v_linux.zip
|
unzip v_linux.zip
|
||||||
cd v
|
cd v
|
||||||
./v -version
|
./v -version
|
||||||
- name: Test V
|
- name: Test V
|
||||||
run: |
|
run: |
|
||||||
cd v
|
cd v
|
||||||
./v run examples/hello_world.v
|
./v run examples/hello_world.v
|
||||||
./v -showcc -gc none -cc tcc -no-retry-compilation run examples/hello_world.v
|
./v -showcc -gc none -cc tcc -no-retry-compilation run examples/hello_world.v
|
||||||
|
|
||||||
macos-arm64:
|
macos-arm64:
|
||||||
## macos-14 is a m1 runner
|
## macos-14 is a m1 runner
|
||||||
runs-on: macos-14
|
runs-on: macos-14
|
||||||
timeout-minutes: 5
|
timeout-minutes: 5
|
||||||
steps:
|
steps:
|
||||||
- name: Download V
|
- name: Download V
|
||||||
run: |
|
run: |
|
||||||
wget https://github.com/vlang/v/releases/latest/download/v_macos_arm64.zip
|
wget https://github.com/vlang/v/releases/latest/download/v_macos_arm64.zip
|
||||||
unzip v_macos_arm64.zip
|
unzip v_macos_arm64.zip
|
||||||
cd v
|
cd v
|
||||||
./v -version
|
./v -version
|
||||||
- name: Test V
|
- name: Test V
|
||||||
run: |
|
run: |
|
||||||
cd v
|
cd v
|
||||||
./v run examples/hello_world.v
|
./v run examples/hello_world.v
|
||||||
./v -showcc -gc none -cc tcc -no-retry-compilation run examples/hello_world.v
|
./v -showcc -gc none -cc tcc -no-retry-compilation run examples/hello_world.v
|
||||||
|
|
||||||
macos-x86_64:
|
macos-x86_64:
|
||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
timeout-minutes: 5
|
timeout-minutes: 5
|
||||||
steps:
|
steps:
|
||||||
- name: Download V
|
- name: Download V
|
||||||
run: |
|
run: |
|
||||||
wget https://github.com/vlang/v/releases/latest/download/v_macos_x86_64.zip
|
wget https://github.com/vlang/v/releases/latest/download/v_macos_x86_64.zip
|
||||||
unzip v_macos_x86_64.zip
|
unzip v_macos_x86_64.zip
|
||||||
cd v
|
cd v
|
||||||
./v -version
|
./v -version
|
||||||
- name: Test V
|
- name: Test V
|
||||||
run: |
|
run: |
|
||||||
cd v
|
cd v
|
||||||
./v run examples/hello_world.v
|
./v run examples/hello_world.v
|
||||||
|
|
||||||
windows:
|
windows:
|
||||||
runs-on: windows-latest
|
runs-on: windows-latest
|
||||||
timeout-minutes: 5
|
timeout-minutes: 5
|
||||||
steps:
|
steps:
|
||||||
- name: Download V
|
- name: Download V
|
||||||
run: |
|
run: |
|
||||||
curl -L https://github.com/vlang/v/releases/latest/download/v_windows.zip -o v_windows.zip
|
curl -L https://github.com/vlang/v/releases/latest/download/v_windows.zip -o v_windows.zip
|
||||||
unzip .\v_windows.zip
|
unzip .\v_windows.zip
|
||||||
cd v
|
cd v
|
||||||
.\v.exe -version
|
.\v.exe -version
|
||||||
- name: Test V
|
- name: Test V
|
||||||
run: |
|
run: |
|
||||||
cd v
|
cd v
|
||||||
.\v.exe run .\examples\hello_world.v
|
.\v.exe run .\examples\hello_world.v
|
||||||
.\v.exe -showcc -gc none -cc tcc -no-retry-compilation run .\examples/hello_world.v
|
.\v.exe -showcc -gc none -cc tcc -no-retry-compilation run .\examples/hello_world.v
|
||||||
|
3
.github/workflows/sanitized_ci.yml
vendored
3
.github/workflows/sanitized_ci.yml
vendored
@ -147,8 +147,7 @@ jobs:
|
|||||||
- name: Self tests (-fsanitize=address)
|
- name: Self tests (-fsanitize=address)
|
||||||
run: ASAN_OPTIONS=detect_leaks=0 ./v -cflags "-fsanitize=address,pointer-compare,pointer-subtract" test-self vlib
|
run: ASAN_OPTIONS=detect_leaks=0 ./v -cflags "-fsanitize=address,pointer-compare,pointer-subtract" test-self vlib
|
||||||
- name: Self tests (V compiled with -fsanitize=address)
|
- name: Self tests (V compiled with -fsanitize=address)
|
||||||
run:
|
run: ./v -cflags -fsanitize=address -o v cmd/v &&
|
||||||
./v -cflags -fsanitize=address -o v cmd/v &&
|
|
||||||
ASAN_OPTIONS=detect_leaks=0 ./v -cc tcc test-self -asan-compiler vlib
|
ASAN_OPTIONS=detect_leaks=0 ./v -cc tcc test-self -asan-compiler vlib
|
||||||
- name: Build examples (V compiled with -fsanitize=address)
|
- name: Build examples (V compiled with -fsanitize=address)
|
||||||
run: ASAN_OPTIONS=detect_leaks=0 ./v build-examples
|
run: ASAN_OPTIONS=detect_leaks=0 ./v build-examples
|
||||||
|
8
.github/workflows/vinix_ci.yml
vendored
8
.github/workflows/vinix_ci.yml
vendored
@ -4,14 +4,14 @@ on:
|
|||||||
workflow_call:
|
workflow_call:
|
||||||
pull_request:
|
pull_request:
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.md"
|
- '**.md'
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- "**.md"
|
- '**.md'
|
||||||
- "**.yml"
|
- '**.yml'
|
||||||
- "!**/vinix_ci.yml"
|
- '!**/vinix_ci.yml'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.sha || github.ref }}
|
group: ${{ github.workflow }}-${{ github.ref == 'refs/heads/master' && github.sha || github.ref }}
|
||||||
|
19
.github/workflows/workflow_lint.yml
vendored
Normal file
19
.github/workflows/workflow_lint.yml
vendored
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
name: Workflow Lint
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
paths:
|
||||||
|
- '**.yml'
|
||||||
|
pull_request:
|
||||||
|
paths:
|
||||||
|
- '**.yml'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
format:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- name: Verify formatting
|
||||||
|
uses: creyD/prettier_action@v4.3
|
||||||
|
with:
|
||||||
|
prettier_options: --check .github/**/**.yml
|
Loading…
x
Reference in New Issue
Block a user