-
Notifications
You must be signed in to change notification settings - Fork 652
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into elp-equatable
- Loading branch information
Showing
477 changed files
with
28,055 additions
and
16,611 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Adopt swift-format | ||
c9756e108351a1def2e2c83ff5ee6fb9bcbc3bbf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
changelog: | ||
categories: | ||
- title: SemVer Major | ||
labels: | ||
- semver/major | ||
- title: SemVer Minor | ||
labels: | ||
- semver/minor | ||
- title: SemVer Patch | ||
labels: | ||
- semver/patch | ||
- title: Other Changes | ||
labels: | ||
- semver/none |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Benchmarks | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
benchmark_package_path: | ||
type: string | ||
description: "Path to the directory containing the benchmarking package. Defaults to ." | ||
default: "." | ||
swift_package_arguments: | ||
type: string | ||
description: "Arguments to the switch package command invocation e.g. `--disable-sandbox`" | ||
linux_5_8_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.8 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_5_9_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.9 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_5_10_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.10 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_nightly_6_0_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux nightly 6.0 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_nightly_main_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux nightly main Swift version matrix job. Defaults to true." | ||
default: true | ||
|
||
jobs: | ||
benchmarks: | ||
name: Benchmarks | ||
uses: ./.github/workflows/swift_matrix.yml | ||
with: | ||
name: "Benchmarks" | ||
matrix_linux_command: "apt-get update -y -q && apt-get install -y -q libjemalloc-dev && swift package --package-path ${{ inputs.benchmark_package_path }} ${{ inputs.swift_package_arguments }} benchmark baseline check --check-absolute-path ${{ inputs.benchmark_package_path }}/Thresholds/${SWIFT_VERSION}/" | ||
matrix_linux_5_8_enabled: ${{ inputs.linux_5_8_enabled }} | ||
matrix_linux_5_9_enabled: ${{ inputs.linux_5_9_enabled }} | ||
matrix_linux_5_10_enabled: ${{ inputs.linux_5_10_enabled }} | ||
matrix_linux_nightly_6_0_enabled: ${{ inputs.linux_nightly_6_0_enabled }} | ||
matrix_linux_nightly_main_enabled: ${{ inputs.linux_nightly_main_enabled }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Cxx interop | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
linux_5_8_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.8 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_5_9_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.9 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_5_10_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux 5.10 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_nightly_6_0_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux nightly 6.0 Swift version matrix job. Defaults to true." | ||
default: true | ||
linux_nightly_main_enabled: | ||
type: boolean | ||
description: "Boolean to enable the Linux nightly main Swift version matrix job. Defaults to true." | ||
default: true | ||
|
||
jobs: | ||
cxx-interop: | ||
name: Cxx interop | ||
uses: ./.github/workflows/swift_matrix.yml | ||
with: | ||
name: "Cxx interop" | ||
matrix_linux_command: "apt-get update -y -q && apt-get install -y -q jq && curl -s https://raw.githubusercontent.com/apple/swift-nio/main/scripts/check-cxx-interop-compatibility.sh | bash" | ||
matrix_linux_5_8_enabled: ${{ inputs.linux_5_8_enabled }} | ||
matrix_linux_5_9_enabled: ${{ inputs.linux_5_9_enabled }} | ||
matrix_linux_5_10_enabled: ${{ inputs.linux_5_10_enabled }} | ||
matrix_linux_nightly_6_0_enabled: ${{ inputs.linux_nightly_6_0_enabled }} | ||
matrix_linux_nightly_main_enabled: ${{ inputs.linux_nightly_main_enabled }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: PR | ||
|
||
on: | ||
pull_request: | ||
types: [opened, reopened, synchronize] | ||
|
||
jobs: | ||
soundness: | ||
name: Soundness | ||
uses: ./.github/workflows/soundness.yml | ||
with: | ||
license_header_check_project_name: "SwiftNIO" | ||
|
||
unit-tests: | ||
name: Unit tests | ||
uses: ./.github/workflows/unit_tests.yml | ||
with: | ||
linux_5_8_arguments_override: "-Xswiftc -warnings-as-errors --explicit-target-dependency-import-check error" | ||
linux_5_9_arguments_override: "-Xswiftc -warnings-as-errors --explicit-target-dependency-import-check error" | ||
linux_5_10_arguments_override: "-Xswiftc -warnings-as-errors --explicit-target-dependency-import-check error" | ||
linux_nightly_6_0_arguments_override: "--explicit-target-dependency-import-check error" | ||
linux_nightly_main_arguments_override: "--explicit-target-dependency-import-check error" | ||
|
||
benchmarks: | ||
name: Benchmarks | ||
uses: ./.github/workflows/benchmarks.yml | ||
with: | ||
benchmark_package_path: "Benchmarks" | ||
|
||
cxx-interop: | ||
name: Cxx interop | ||
uses: ./.github/workflows/cxx_interop.yml | ||
|
||
integration-tests: | ||
name: Integration Tests | ||
uses: ./.github/workflows/swift_matrix.yml | ||
with: | ||
name: "Integration tests" | ||
matrix_linux_command: "apt-get update -y -q && apt-get install -y -q lsof dnsutils netcat-openbsd net-tools curl jq && ./scripts/integration_tests.sh" | ||
|
||
swift-6-language-mode: | ||
name: Swift 6 Language Mode | ||
uses: ./.github/workflows/swift_6_language_mode.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,150 @@ | ||
name: Soundness | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
api_breakage_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the API breakage check job. Defaults to true." | ||
default: true | ||
docs_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the docs check job. Defaults to true." | ||
default: true | ||
unacceptable_language_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the acceptable language check job. Defaults to true." | ||
default: true | ||
unacceptable_language_check_word_list: | ||
type: string | ||
description: "List of unacceptable words. Defaults to a sensible list of words." | ||
default: "blacklist whitelist slave master sane sanity insane insanity kill killed killing hang hung hanged hanging" #ignore-unacceptable-language | ||
license_header_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the license header check job. Defaults to true." | ||
default: true | ||
license_header_check_project_name: | ||
type: string | ||
description: "Name of the project called out in the license header." | ||
required: true | ||
broken_symlink_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the broken symlink check job. Defaults to true." | ||
default: true | ||
format_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the format check job. Defaults to true." | ||
default: true | ||
shell_check_enabled: | ||
type: boolean | ||
description: "Boolean to enable the shell check job. Defaults to true." | ||
default: true | ||
|
||
## We are cancelling previously triggered workflow runs | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }}-soundness | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
api-breakage-check: | ||
name: API breakage check | ||
if: ${{ inputs.api_breakage_check_enabled }} | ||
runs-on: ubuntu-latest | ||
container: | ||
image: swift:5.10-noble | ||
timeout-minutes: 20 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
with: | ||
# We need to fetch everything otherwise only the head commit will be fetched. | ||
fetch-depth: 0 | ||
- name: Mark the workspace as safe | ||
# https://github.com/actions/checkout/issues/766 | ||
run: git config --global --add safe.directory ${GITHUB_WORKSPACE} | ||
- name: Run API breakage check | ||
run: swift package diagnose-api-breaking-changes origin/main | ||
|
||
docs-check: | ||
name: Documentation check | ||
if: ${{ inputs.docs_check_enabled }} | ||
runs-on: ubuntu-latest | ||
container: | ||
image: swift:5.10-noble | ||
timeout-minutes: 20 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Run documentation check | ||
run: | | ||
apt-get -qq update && apt-get -qq -y install curl yq | ||
curl -s https://raw.githubusercontent.com/apple/swift-nio/main/scripts/check-docs.sh | bash | ||
unacceptable-language-check: | ||
name: Unacceptable language check | ||
if: ${{ inputs.unacceptable_language_check_enabled }} | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 1 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Run unacceptable language check | ||
env: | ||
UNACCEPTABLE_WORD_LIST: ${{ inputs.unacceptable_language_check_word_list}} | ||
run: curl -s https://raw.githubusercontent.com/apple/swift-nio/main/scripts/check-unacceptable-language.sh | bash | ||
|
||
license-header-check: | ||
name: License headers check | ||
if: ${{ inputs.license_header_check_enabled }} | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 1 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Run license header check | ||
env: | ||
PROJECT_NAME: ${{ inputs.license_header_check_project_name }} | ||
run: curl -s https://raw.githubusercontent.com/apple/swift-nio/main/scripts/check-license-header.sh | bash | ||
|
||
broken-symlink-check: | ||
name: Broken symlinks check | ||
if: ${{ inputs.broken_symlink_check_enabled }} | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 1 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Run broken symlinks check | ||
run: curl -s https://raw.githubusercontent.com/apple/swift-nio/main/scripts/check-broken-symlinks.sh | bash | ||
|
||
format-check: | ||
name: Format check | ||
if: ${{ inputs.format_check_enabled }} | ||
runs-on: ubuntu-latest | ||
container: | ||
image: swiftlang/swift:nightly-6.0-jammy | ||
timeout-minutes: 5 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Mark the workspace as safe | ||
# https://github.com/actions/checkout/issues/766 | ||
run: git config --global --add safe.directory ${GITHUB_WORKSPACE} | ||
- name: Run format check | ||
run: | | ||
apt-get -qq update && apt-get -qq -y install curl | ||
curl -s https://raw.githubusercontent.com/apple/swift-nio/main/scripts/check-swift-format.sh | bash | ||
shell-check: | ||
name: Shell check | ||
if: ${{ inputs.shell_check_enabled }} | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 5 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Mark the workspace as safe | ||
# https://github.com/actions/checkout/issues/766 | ||
run: git config --global --add safe.directory ${GITHUB_WORKSPACE} | ||
- name: Run shellcheck | ||
run: git ls-files -z '*.sh' | xargs -0 shellcheck |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Swift 6 language mode | ||
|
||
on: | ||
workflow_call: | ||
|
||
## We are cancelling previously triggered workflow runs | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }}-swift-6-language-mode | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
swift-6-language-mode: | ||
name: Swift 6 language mode | ||
runs-on: ubuntu-latest | ||
container: | ||
image: swiftlang/swift:nightly-6.0-jammy | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Set the language mode | ||
run: swift package tools-version --set 6.0 | ||
- name: Build with Swift 6 language mode | ||
run: swift build -Xswiftc -warnings-as-errors |
Oops, something went wrong.