-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update from hummingbird-community-template 7060a552b0ce8b141bf9c4ac22…
…4dd9565d2fd786
- Loading branch information
1 parent
096decd
commit 85548ab
Showing
11 changed files
with
259 additions
and
8 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 @@ | ||
.build | ||
.git |
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,21 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "daily" | ||
groups: | ||
dependencies: | ||
patterns: | ||
- "*" | ||
- package-ecosystem: "swift" | ||
directory: "/" | ||
schedule: | ||
interval: "daily" | ||
open-pull-requests-limit: 5 | ||
allow: | ||
- dependency-type: all | ||
groups: | ||
all-dependencies: | ||
patterns: | ||
- "*" |
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,22 @@ | ||
name: API breaking changes | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
linux: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
container: | ||
image: swift:5.10 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
# https://github.com/actions/checkout/issues/766 | ||
- name: Mark the workspace as safe | ||
run: git config --global --add safe.directory ${GITHUB_WORKSPACE} | ||
- name: API breaking changes | ||
run: | | ||
swift package diagnose-api-breaking-changes origin/${GITHUB_BASE_REF} |
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,39 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '**.swift' | ||
- '**.yml' | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
linux: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
strategy: | ||
matrix: | ||
image: ["swift:5.9", "swift:5.10"] | ||
|
||
container: | ||
image: ${{ matrix.image }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Test | ||
run: | | ||
swift test --enable-code-coverage | ||
- name: Convert coverage files | ||
run: | | ||
llvm-cov export -format="lcov" \ | ||
.build/debug/hummingbird-elementaryPackageTests.xctest \ | ||
-ignore-filename-regex="\/Tests\/" \ | ||
-ignore-filename-regex="\/Benchmarks\/" \ | ||
-instr-profile .build/debug/codecov/default.profdata > info.lcov | ||
- name: Upload to codecov.io | ||
uses: codecov/codecov-action@v4 | ||
with: | ||
file: info.lcov |
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,21 @@ | ||
name: Swift nightly build | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
linux: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 15 | ||
strategy: | ||
matrix: | ||
image: ['nightly-focal', 'nightly-jammy', 'nightly-amazonlinux2'] | ||
|
||
container: | ||
image: swiftlang/swift:${{ matrix.image }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Test | ||
run: | | ||
swift test |
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,21 @@ | ||
name: Validity Check | ||
|
||
on: | ||
pull_request: | ||
workflow_dispatch: | ||
|
||
jobs: | ||
validate: | ||
runs-on: macOS-latest | ||
timeout-minutes: 15 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 1 | ||
- name: Install Dependencies | ||
run: | | ||
brew install mint | ||
mint install NickLockwood/SwiftFormat@0.53.10 --no-link | ||
- name: run script | ||
run: ./scripts/validate.sh |
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 |
---|---|---|
@@ -1,9 +1,12 @@ | ||
.DS_Store | ||
/.build | ||
.build/ | ||
.swiftpm/ | ||
.vscode/ | ||
.devcontainer/ | ||
/Packages | ||
/*.xcodeproj | ||
xcuserdata/ | ||
DerivedData/ | ||
.swiftpm/configuration/registries.json | ||
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata | ||
.netrc | ||
Package.resolved | ||
Package.resolved | ||
/public | ||
/docs | ||
.benchmarkBaselines |
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
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,54 @@ | ||
# Code of Conduct | ||
|
||
All developers should feel welcome and encouraged to contribute to Hummingbird. Because of this we have adopted the code of conduct defined by [contributor-covenant.org](https://www.contributor-covenant.org). This document is used across many open source | ||
communities, and we think it articulates our values well. The full text is copied below: | ||
|
||
## Contributor Code of Conduct v1.3 | ||
|
||
As contributors and maintainers of this project, and in the interest of | ||
fostering an open and welcoming community, we pledge to respect all people who | ||
contribute through reporting issues, posting feature requests, updating | ||
documentation, submitting pull requests or patches, and other activities. | ||
|
||
We are committed to making participation in this project a harassment-free | ||
experience for everyone, regardless of level of experience, gender, gender | ||
identity and expression, sexual orientation, disability, personal appearance, | ||
body size, race, ethnicity, age, religion, or nationality. | ||
|
||
Examples of unacceptable behavior by participants include: | ||
|
||
* The use of sexualized language or imagery | ||
* Personal attacks | ||
* Trolling or insulting/derogatory comments | ||
* Public or private harassment | ||
* Publishing other's private information, such as physical or electronic | ||
addresses, without explicit permission | ||
* Other unethical or unprofessional conduct | ||
|
||
Project maintainers have the right and responsibility to remove, edit, or | ||
reject comments, commits, code, wiki edits, issues, and other contributions | ||
that are not aligned to this Code of Conduct, or to ban temporarily or | ||
permanently any contributor for other behaviors that they deem inappropriate, | ||
threatening, offensive, or harmful. | ||
|
||
By adopting this Code of Conduct, project maintainers commit themselves to | ||
fairly and consistently applying these principles to every aspect of managing | ||
this project. Project maintainers who do not follow or enforce the Code of | ||
Conduct may be permanently removed from the project team. | ||
|
||
This Code of Conduct applies both within project spaces and in public spaces | ||
when an individual is representing the project or its community. | ||
|
||
Instances of abusive, harassing, or otherwise unacceptable behavior may be | ||
reported by contacting a project maintainer at [INSERT EMAIL ADDRESS]. All | ||
complaints will be reviewed and investigated and will result in a response that | ||
is deemed necessary and appropriate to the circumstances. Maintainers are | ||
obligated to maintain confidentiality with regard to the reporter of an | ||
incident. | ||
|
||
|
||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], | ||
version 1.3.0, available at https://www.contributor-covenant.org/version/1/3/0/code-of-conduct.html | ||
|
||
[homepage]: https://www.contributor-covenant.org | ||
|
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,29 @@ | ||
# Contributing | ||
|
||
|
||
## Legal | ||
By submitting a pull request, you represent that you have the right to license your contribution to the community, and agree by submitting the patch | ||
that your contributions are licensed under the Apache 2.0 license (see [LICENSE](LICENSE)). | ||
|
||
## Contributor Conduct | ||
All contributors are expected to adhere to the project's [Code of Conduct](CODE_OF_CONDUCT.md). | ||
|
||
## Submitting a bug or issue | ||
Please ensure to include the following in your bug report | ||
- A consise description of the issue, what happened and what you expected. | ||
- Simple reproduction steps | ||
- Version of the library you are using | ||
- Contextual information (Swift version, OS etc) | ||
|
||
## Submitting a Pull Request | ||
|
||
Please ensure to include the following in your Pull Request | ||
- A description of what you are trying to do. What the PR provides to the library, additional functionality, fixing a bug etc | ||
- A description of the code changes | ||
- Documentation on how these changes are being tested | ||
- Additional tests to show your code working and to ensure future changes don't break your code. | ||
|
||
Please keep your PRs to a minimal number of changes. If a PR is large try to split it up into smaller PRs. Don't move code around unnecessarily it makes comparing old with new very hard. | ||
|
||
The main development branch of the repository is `main`. | ||
|
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,39 @@ | ||
#!/bin/bash | ||
##===----------------------------------------------------------------------===## | ||
## | ||
## This source file is part of the SwiftNIO open source project | ||
## | ||
## Copyright (c) 2017-2019 Apple Inc. and the SwiftNIO project authors | ||
## Licensed under Apache License v2.0 | ||
## | ||
## See LICENSE.txt for license information | ||
## See CONTRIBUTORS.txt for the list of SwiftNIO project authors | ||
## | ||
## SPDX-License-Identifier: Apache-2.0 | ||
## | ||
##===----------------------------------------------------------------------===## | ||
|
||
SWIFT_FORMAT_VERSION=0.53.10 | ||
|
||
set -eu | ||
here="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
|
||
which swiftformat > /dev/null 2>&1 || (echo "swiftformat not installed. You can install it using 'brew install swiftformat'" ; exit -1) | ||
|
||
printf "=> Checking format... " | ||
FIRST_OUT="$(git status --porcelain)" | ||
if [[ -n "${CI-""}" ]]; then | ||
printf "(using v$(mint run NickLockwood/SwiftFormat@"$SWIFT_FORMAT_VERSION" --version)) " | ||
mint run NickLockwood/SwiftFormat@"$SWIFT_FORMAT_VERSION" . > /dev/null 2>&1 | ||
else | ||
printf "(using v$(swiftformat --version)) " | ||
swiftformat . > /dev/null 2>&1 | ||
fi | ||
SECOND_OUT="$(git status --porcelain)" | ||
if [[ "$FIRST_OUT" != "$SECOND_OUT" ]]; then | ||
printf "\033[0;31mformatting issues!\033[0m\n" | ||
git --no-pager diff | ||
exit 1 | ||
else | ||
printf "\033[0;32mokay.\033[0m\n" | ||
fi |