streams #184
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 workflow was automatically generated by ActionBuilderTool 1.0. | |
# (see https://github.com/elegantchaos/ActionBuilderCore for more details) | |
# -------------------------------------------------------------------------------- | |
name: Tests | |
on: [push, pull_request] | |
jobs: | |
linux-swift57: | |
name: Linux (Swift 5.7) | |
runs-on: ubuntu-18.04 | |
container: swiftlang/swift:nightly-5.7-bionic | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Make Logs Directory | |
run: mkdir logs | |
- name: Swift Version | |
run: swift --version | |
- name: Test (release) | |
run: swift test --configuration release -Xswiftc -enable-testing | |
- name: Upload Logs | |
uses: actions/upload-artifact@v1 | |
if: always() | |
with: | |
name: logs | |
path: logs | |
linux-swift56: | |
name: Linux (Swift 5.6) | |
runs-on: ubuntu-18.04 | |
container: swift:5.6.2-bionic | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Make Logs Directory | |
run: mkdir logs | |
- name: Swift Version | |
run: swift --version | |
- name: Test (release) | |
run: swift test --configuration release -Xswiftc -enable-testing | |
- name: Upload Logs | |
uses: actions/upload-artifact@v1 | |
if: always() | |
with: | |
name: logs | |
path: logs | |
macOS-swift57: | |
name: macOS (Swift 5.7) | |
env: | |
TOOLCHAINS: swift | |
runs-on: macos-12 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Make Logs Directory | |
run: mkdir logs | |
- name: Install Toolchain | |
run: | | |
branch="swift-5.7-branch" | |
wget --quiet https://download.swift.org/$branch/xcode/latest-build.yml | |
grep "download:" < latest-build.yml > filtered.yml | |
sed -e 's/-osx.pkg//g' filtered.yml > stripped.yml | |
sed -e 's/:[^:\/\/]/YML="/g;s/$/"/g;s/ *=/=/g' stripped.yml > snapshot.sh | |
source snapshot.sh | |
echo "Installing Toolchain: $downloadYML" | |
wget --quiet https://swift.org/builds/$branch/xcode/$downloadYML/$downloadYML-osx.pkg | |
sudo installer -pkg $downloadYML-osx.pkg -target / | |
ln -s "/Library/Developer/Toolchains/$downloadYML.xctoolchain/usr/bin" swift-latest | |
ls -d /Applications/Xcode* | |
sudo xcode-select -s /Applications/Xcode_13.4.1.app | |
swift --version | |
- name: Xcode Version | |
run: | | |
xcodebuild -version | |
xcrun swift --version | |
- name: Swift Version | |
run: swift --version | |
- name: Test (release) | |
run: export PATH="swift-latest:$PATH"; swift test --configuration release -Xswiftc -enable-testing | |
- name: Upload Logs | |
uses: actions/upload-artifact@v1 | |
if: always() | |
with: | |
name: logs | |
path: logs | |
macOS-swift56: | |
name: macOS (Swift 5.6) | |
runs-on: macos-12 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Make Logs Directory | |
run: mkdir logs | |
- name: Install Toolchain | |
run: | | |
branch="swift-5.7-branch" | |
wget --quiet https://download.swift.org/$branch/xcode/latest-build.yml | |
grep "download:" < latest-build.yml > filtered.yml | |
sed -e 's/-osx.pkg//g' filtered.yml > stripped.yml | |
sed -e 's/:[^:\/\/]/YML="/g;s/$/"/g;s/ *=/=/g' stripped.yml > snapshot.sh | |
source snapshot.sh | |
echo "Installing Toolchain: $downloadYML" | |
wget --quiet https://swift.org/builds/$branch/xcode/$downloadYML/$downloadYML-osx.pkg | |
sudo installer -pkg $downloadYML-osx.pkg -target / | |
ln -s "/Library/Developer/Toolchains/$downloadYML.xctoolchain/usr/bin" swift-latest | |
ls -d /Applications/Xcode* | |
sudo xcode-select -s /Applications/Xcode_13.4.1.app | |
swift --version | |
- name: Xcode Version | |
run: | | |
xcodebuild -version | |
xcrun swift --version | |
- name: Swift Version | |
run: swift --version | |
- name: Test (release) | |
run: export PATH="swift-latest:$PATH"; swift test --configuration release -Xswiftc -enable-testing | |
- name: Upload Logs | |
uses: actions/upload-artifact@v1 | |
if: always() | |
with: | |
name: logs | |
path: logs | |
xcode-swift57: | |
name: iOS/watchOS/tvOS (Swift 5.7, Xcode 13.4.1) | |
env: | |
TOOLCHAINS: swift | |
runs-on: macos-12 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Make Logs Directory | |
run: mkdir logs | |
- name: Install Toolchain | |
run: | | |
branch="swift-5.7-branch" | |
wget --quiet https://download.swift.org/$branch/xcode/latest-build.yml | |
grep "download:" < latest-build.yml > filtered.yml | |
sed -e 's/-osx.pkg//g' filtered.yml > stripped.yml | |
sed -e 's/:[^:\/\/]/YML="/g;s/$/"/g;s/ *=/=/g' stripped.yml > snapshot.sh | |
source snapshot.sh | |
echo "Installing Toolchain: $downloadYML" | |
wget --quiet https://swift.org/builds/$branch/xcode/$downloadYML/$downloadYML-osx.pkg | |
sudo installer -pkg $downloadYML-osx.pkg -target / | |
ln -s "/Library/Developer/Toolchains/$downloadYML.xctoolchain/usr/bin" swift-latest | |
ls -d /Applications/Xcode* | |
sudo xcode-select -s /Applications/Xcode_13.4.1.app | |
swift --version | |
- name: Xcode Version | |
run: | | |
xcodebuild -version | |
xcrun swift --version | |
- name: XC Pretty | |
run: sudo gem install xcpretty-travis-formatter | |
- name: Detect Workspace & Scheme (iOS) | |
run: | | |
WORKSPACE="Logger.xcworkspace" | |
if [[ ! -e "$WORKSPACE" ]] | |
then | |
WORKSPACE="." | |
GOTPACKAGE=$(xcodebuild -workspace . -list | (grep Logger-Package || true)) | |
if [[ $GOTPACKAGE != "" ]] | |
then | |
SCHEME="Logger-Package" | |
else | |
SCHEME="Logger" | |
fi | |
else | |
SCHEME="Logger-iOS" | |
fi | |
echo "set -o pipefail; export PATH='swift-latest:$PATH'; WORKSPACE='$WORKSPACE'; SCHEME='$SCHEME'" > setup.sh | |
- name: Build (iOS release) | |
run: | | |
source "setup.sh" | |
echo "Building workspace $WORKSPACE scheme $SCHEME." | |
xcodebuild clean build -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "name=iPhone 11" -configuration Release CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_TESTABILITY=YES | tee logs/xcodebuild-iOS-build-release.log | xcpretty | |
- name: Detect Workspace & Scheme (watchOS) | |
run: | | |
WORKSPACE="Logger.xcworkspace" | |
if [[ ! -e "$WORKSPACE" ]] | |
then | |
WORKSPACE="." | |
GOTPACKAGE=$(xcodebuild -workspace . -list | (grep Logger-Package || true)) | |
if [[ $GOTPACKAGE != "" ]] | |
then | |
SCHEME="Logger-Package" | |
else | |
SCHEME="Logger" | |
fi | |
else | |
SCHEME="Logger-watchOS" | |
fi | |
echo "set -o pipefail; export PATH='swift-latest:$PATH'; WORKSPACE='$WORKSPACE'; SCHEME='$SCHEME'" > setup.sh | |
- name: Build (watchOS release) | |
run: | | |
source "setup.sh" | |
echo "Building workspace $WORKSPACE scheme $SCHEME." | |
xcodebuild clean build -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "name=Apple Watch Series 5 - 44mm" -configuration Release CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_TESTABILITY=YES | tee logs/xcodebuild-watchOS-build-release.log | xcpretty | |
- name: Detect Workspace & Scheme (tvOS) | |
run: | | |
WORKSPACE="Logger.xcworkspace" | |
if [[ ! -e "$WORKSPACE" ]] | |
then | |
WORKSPACE="." | |
GOTPACKAGE=$(xcodebuild -workspace . -list | (grep Logger-Package || true)) | |
if [[ $GOTPACKAGE != "" ]] | |
then | |
SCHEME="Logger-Package" | |
else | |
SCHEME="Logger" | |
fi | |
else | |
SCHEME="Logger-tvOS" | |
fi | |
echo "set -o pipefail; export PATH='swift-latest:$PATH'; WORKSPACE='$WORKSPACE'; SCHEME='$SCHEME'" > setup.sh | |
- name: Build (tvOS release) | |
run: | | |
source "setup.sh" | |
echo "Building workspace $WORKSPACE scheme $SCHEME." | |
xcodebuild clean build -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "name=Apple TV" -configuration Release CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_TESTABILITY=YES | tee logs/xcodebuild-tvOS-build-release.log | xcpretty | |
- name: Upload Logs | |
uses: actions/upload-artifact@v1 | |
if: always() | |
with: | |
name: logs | |
path: logs | |
xcode-swift56: | |
name: iOS/watchOS/tvOS (Swift 5.6, Xcode 13.4.1) | |
runs-on: macos-12 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v1 | |
- name: Make Logs Directory | |
run: mkdir logs | |
- name: Install Toolchain | |
run: | | |
branch="swift-5.7-branch" | |
wget --quiet https://download.swift.org/$branch/xcode/latest-build.yml | |
grep "download:" < latest-build.yml > filtered.yml | |
sed -e 's/-osx.pkg//g' filtered.yml > stripped.yml | |
sed -e 's/:[^:\/\/]/YML="/g;s/$/"/g;s/ *=/=/g' stripped.yml > snapshot.sh | |
source snapshot.sh | |
echo "Installing Toolchain: $downloadYML" | |
wget --quiet https://swift.org/builds/$branch/xcode/$downloadYML/$downloadYML-osx.pkg | |
sudo installer -pkg $downloadYML-osx.pkg -target / | |
ln -s "/Library/Developer/Toolchains/$downloadYML.xctoolchain/usr/bin" swift-latest | |
ls -d /Applications/Xcode* | |
sudo xcode-select -s /Applications/Xcode_13.4.1.app | |
swift --version | |
- name: Xcode Version | |
run: | | |
xcodebuild -version | |
xcrun swift --version | |
- name: XC Pretty | |
run: sudo gem install xcpretty-travis-formatter | |
- name: Detect Workspace & Scheme (iOS) | |
run: | | |
WORKSPACE="Logger.xcworkspace" | |
if [[ ! -e "$WORKSPACE" ]] | |
then | |
WORKSPACE="." | |
GOTPACKAGE=$(xcodebuild -workspace . -list | (grep Logger-Package || true)) | |
if [[ $GOTPACKAGE != "" ]] | |
then | |
SCHEME="Logger-Package" | |
else | |
SCHEME="Logger" | |
fi | |
else | |
SCHEME="Logger-iOS" | |
fi | |
echo "set -o pipefail; export PATH='swift-latest:$PATH'; WORKSPACE='$WORKSPACE'; SCHEME='$SCHEME'" > setup.sh | |
- name: Test (iOS Release) | |
run: | | |
source "setup.sh" | |
echo "Testing workspace $WORKSPACE scheme $SCHEME." | |
xcodebuild test -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "name=iPhone 11" -configuration Release CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_TESTABILITY=YES | tee logs/xcodebuild-iOS-test-release.log | xcpretty | |
- name: Detect Workspace & Scheme (watchOS) | |
run: | | |
WORKSPACE="Logger.xcworkspace" | |
if [[ ! -e "$WORKSPACE" ]] | |
then | |
WORKSPACE="." | |
GOTPACKAGE=$(xcodebuild -workspace . -list | (grep Logger-Package || true)) | |
if [[ $GOTPACKAGE != "" ]] | |
then | |
SCHEME="Logger-Package" | |
else | |
SCHEME="Logger" | |
fi | |
else | |
SCHEME="Logger-watchOS" | |
fi | |
echo "set -o pipefail; export PATH='swift-latest:$PATH'; WORKSPACE='$WORKSPACE'; SCHEME='$SCHEME'" > setup.sh | |
- name: Build (watchOS release) | |
run: | | |
source "setup.sh" | |
echo "Building workspace $WORKSPACE scheme $SCHEME." | |
xcodebuild clean build -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "name=Apple Watch Series 5 - 44mm" -configuration Release CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_TESTABILITY=YES | tee logs/xcodebuild-watchOS-build-release.log | xcpretty | |
- name: Detect Workspace & Scheme (tvOS) | |
run: | | |
WORKSPACE="Logger.xcworkspace" | |
if [[ ! -e "$WORKSPACE" ]] | |
then | |
WORKSPACE="." | |
GOTPACKAGE=$(xcodebuild -workspace . -list | (grep Logger-Package || true)) | |
if [[ $GOTPACKAGE != "" ]] | |
then | |
SCHEME="Logger-Package" | |
else | |
SCHEME="Logger" | |
fi | |
else | |
SCHEME="Logger-tvOS" | |
fi | |
echo "set -o pipefail; export PATH='swift-latest:$PATH'; WORKSPACE='$WORKSPACE'; SCHEME='$SCHEME'" > setup.sh | |
- name: Test (tvOS Release) | |
run: | | |
source "setup.sh" | |
echo "Testing workspace $WORKSPACE scheme $SCHEME." | |
xcodebuild test -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "name=Apple TV" -configuration Release CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO ENABLE_TESTABILITY=YES | tee logs/xcodebuild-tvOS-test-release.log | xcpretty | |
- name: Upload Logs | |
uses: actions/upload-artifact@v1 | |
if: always() | |
with: | |
name: logs | |
path: logs | |