Skip to content

Commit 284083d

Browse files
Update to Apodini 0.5.0 and make the project REUSE compliant (#3)
1 parent 3b9aebd commit 284083d

File tree

96 files changed

+924
-1041
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

96 files changed

+924
-1041
lines changed

.github/pull_request_template.md

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
1+
<!--
2+
3+
This source file is part of the Apodini Example open source project
4+
5+
SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
6+
7+
SPDX-License-Identifier: MIT
8+
9+
-->
10+
111
# *Name of the PR*
212

3-
## :recycle: Current situation
13+
## :recycle: Current situation & Problem
414
*Describe the current situation (if possible with and exemplary (or real) code snippet and/or where this is used)*
515

616
## :bulb: Proposed solution
7-
*Describe the solution (if possible with and exemplary (or real) code snippet)*
8-
9-
### Problem that is solved
10-
*Provide a description and link issues that are solved*
17+
*Describe the solution and how this affects the project and internal structure*
1118

12-
### Implications
13-
*Describe the implications, e.g. refactoring*
19+
## :gear: Release Notes
20+
*Add a short summary of the feature as well as possible migration guides if this is a breaking change so this section can be added to the release notes.*
21+
*Include code snippets that provide examples of the feature implemented if it appends or changes the public interface.*
1422

1523
## :heavy_plus_sign: Additional Information
1624
*Provide some additional information if possible*

.github/release-drafter.yml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,30 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
branches: [release]
210
name-template: '$NEXT_PATCH_VERSION'
311
tag-template: '$NEXT_PATCH_VERSION'
412
categories:
5-
- title: '🚀 Features'
13+
- title: 'Semantic Version Major'
14+
labels:
15+
- 'needs version bump'
16+
- title: 'Semantic Version Minor'
617
labels:
718
- 'feature'
819
- 'enhancement'
9-
- title: '🐛 Bug Fixes'
20+
- title: 'Other Changes'
1021
labels:
1122
- 'fix'
1223
- 'bugfix'
1324
- 'bug'
14-
- title: '🧰 Maintenance'
15-
label: 'chore'
25+
- 'documentation'
1626
change-template: '- $TITLE @$AUTHOR (#$NUMBER)'
1727
template: |
1828
## Changes
1929
20-
$CHANGES
30+
$CHANGES
Lines changed: 46 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
name: Build and Test
210

311
on:
@@ -7,14 +15,12 @@ on:
715
pull_request:
816
branches:
917
- develop
18+
workflow_dispatch:
1019

1120
jobs:
1221
macosclient:
1322
name: macOS Client
1423
runs-on: macos-11
15-
defaults:
16-
run:
17-
working-directory: ./App
1824
steps:
1925
- uses: actions/checkout@v2
2026
- uses: maxim-lobanov/[email protected]
@@ -26,34 +32,48 @@ jobs:
2632
run: swift --version
2733
- name: Build and test
2834
run: xcodebuild test -scheme App -destination 'platform=iOS Simulator,OS=15.0,name=iPhone 12'
29-
macoswebservices:
30-
name: macOS WebService
35+
macoswebservice:
36+
name: macOS WebService ${{ matrix.configuration }}
3137
runs-on: macos-11
3238
defaults:
3339
run:
3440
working-directory: ./WebService
41+
strategy:
42+
fail-fast: false
43+
matrix:
44+
configuration: [debug, release]
3545
steps:
3646
- uses: actions/checkout@v2
37-
- uses: maxim-lobanov/setup-xcode@v1.1
47+
- uses: maxim-lobanov/setup-xcode@v1.2.3
3848
with:
3949
xcode-version: latest
50+
- uses: actions/cache@v2
51+
with:
52+
path: .build
53+
key: ${{ runner.os }}-spm-${{ hashFiles('**/Package.resolved') }}
4054
- name: Check Xcode version
4155
run: xcodebuild -version
4256
- name: Check Swift version
4357
run: swift --version
44-
- name: Build and test
45-
run: swift test
58+
- name: Release Build
59+
if: matrix.configuration == 'release'
60+
run: swift build -c release
61+
- name: Debug Build
62+
if: matrix.configuration == 'debug'
63+
run: swift build -c debug
4664
linuxwebservices:
47-
name: Linux WebService ${{ matrix.linux }}
65+
name: Linux ${{ matrix.linux }} ${{ matrix.configuration }}
4866
runs-on: ubuntu-latest
4967
container:
50-
image: swift:${{ matrix.linux }}
51-
strategy:
52-
matrix:
53-
linux: [latest, focal, amazonlinux2, centos8]
68+
image: swiftlang/swift:nightly-5.5-${{ matrix.linux }}
5469
defaults:
5570
run:
5671
working-directory: ./WebService
72+
strategy:
73+
fail-fast: false
74+
matrix:
75+
linux: [bionic, focal, amazonlinux2, centos8]
76+
configuration: [debug, release, release_testing]
5777
steps:
5878
- uses: actions/checkout@v2
5979
- name: Install libsqlite3
@@ -65,7 +85,18 @@ jobs:
6585
- name: Install libsqlite3
6686
if: startsWith( matrix.linux, 'centos' )
6787
run: yum update -y --nobest && yum install -y sqlite-devel
88+
- uses: actions/cache@v2
89+
with:
90+
path: .build
91+
key: ${{ runner.os }}-${{matrix.linux}}-spm-${{ hashFiles('**/Package.resolved') }}
6892
- name: Check Swift version
6993
run: swift --version
70-
- name: Build and test
71-
run: swift test -Xswiftc -Xfrontend -Xswiftc -sil-verify-none
94+
- name: Release Build
95+
if: matrix.configuration == 'release'
96+
run: swift build -c release
97+
- name: Release Build & Test
98+
if: matrix.configuration == 'release_testing'
99+
run: swift test -c release -Xswiftc -enable-testing
100+
- name: Debug Build & Test
101+
if: matrix.configuration == 'debug'
102+
run: swift test -c debug

.github/workflows/docker-compose.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
name: Build Docker Compose
210

311
on:

.github/workflows/docker.yml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,17 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
name: Build Docker Image
210

311
on:
4-
push:
5-
tags:
6-
- '*.*.*'
12+
release:
13+
types: [published]
14+
workflow_dispatch:
715

816
jobs:
917
docker:

.github/workflows/release-drafter.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,17 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
name: Release Drafter
210

311
on:
412
push:
513
branches:
6-
- release
14+
- develop
715

816
jobs:
917
update_release_draft:

.github/workflows/release.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
name: Create Release
210

311
on:
@@ -9,7 +17,7 @@ jobs:
917
build:
1018
runs-on: ubuntu-latest
1119
steps:
12-
- name: GH Release
20+
- name: Create GitHub Release
1321
uses: softprops/[email protected]
1422
env:
1523
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}

.github/workflows/reuseaction.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
9+
name: REUSE Compliance Check
10+
11+
on:
12+
pull_request:
13+
workflow_dispatch:
14+
15+
jobs:
16+
reuse:
17+
name: REUSE Compliance Check
18+
runs-on: ubuntu-latest
19+
steps:
20+
- uses: actions/checkout@v2
21+
- name: REUSE Compliance Check
22+
uses: fsfe/reuse-action@v1

.github/workflows/spm-update.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
9+
name: Swift Package Update
10+
11+
on:
12+
schedule:
13+
- cron: '0 0 * * 1'
14+
workflow_dispatch:
15+
16+
jobs:
17+
createPR:
18+
name: Create Pull Request
19+
container:
20+
image: swiftlang/swift:nightly-5.5-focal
21+
runs-on: ubuntu-latest
22+
steps:
23+
- uses: actions/checkout@v2
24+
- name: Check Swift version
25+
run: swift --version
26+
- name: Update Swift Packages Gateway
27+
run: cd ./Shared && swift package update
28+
- name: Update Swift Packages Database
29+
run: cd ./WebService && swift package update
30+
- name: Update Swift Packages Xcode Projekt
31+
run: |
32+
rm -f Example.xcworkspace/xcshareddata/swiftpm/Package.resolved
33+
xcodebuild -resolvePackageDependencies
34+
- uses: peter-evans/create-pull-request@v3
35+
with:
36+
token: ${{ secrets.ACCESS_TOKEN }}
37+
commit-message: Update dependencies
38+
title: Update dependencies
39+
body: Update the Swift Package dependencies.
40+
delete-branch: true
41+
base: develop
42+
branch: bots/update-dependencies
43+
assignees: ApodiniBot
44+
committer: ApodiniBot <[email protected]>
45+
author: ApodiniBot <[email protected]>
46+
reviewers: PSchmiedmayer

.github/workflows/swiftlint.yml

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,26 @@
1+
#
2+
# This source file is part of the Apodini Example open source project
3+
#
4+
# SPDX-FileCopyrightText: 2018-2021 Paul Schmiedmayer and project authors (see CONTRIBUTORS.md) <[email protected]>
5+
#
6+
# SPDX-License-Identifier: MIT
7+
#
8+
19
name: SwiftLint
210

311
on:
412
pull_request:
5-
paths:
6-
- '.github/workflows/swiftlint.yml'
7-
- '.swiftlint.yml'
8-
- '**/*.swift'
13+
workflow_dispatch:
914

1015
jobs:
1116
swiftlint:
17+
name: SwiftLint
1218
runs-on: ubuntu-latest
1319
steps:
1420
- uses: actions/checkout@v1
1521
- name: GitHub Action for SwiftLint
16-
uses: norio-nomura/action-swiftlint@3.1.0
22+
uses: norio-nomura/action-swiftlint@3.2.1
1723
with:
1824
args: --strict
1925
env:
2026
DIFF_BASE: ${{ github.base_ref }}
21-

0 commit comments

Comments
 (0)