Updating GHES workflows

This commit is contained in:
GitHub Actions
2020-08-24 16:57:10 +00:00
parent fc246debda
commit 1612e273ef
3 changed files with 52 additions and 0 deletions
+42
View File
@@ -0,0 +1,42 @@
name: iOS starter workflow
on:
push:
branches: [ $default-branch ]
pull_request:
branches: [ $default-branch ]
jobs:
build:
name: Build and Test default scheme using any available iPhone simulator
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set Default Scheme
run: |
scheme_list=$(xcodebuild -list -json | tr -d "\n")
default=$(echo $scheme_list | ruby -e "require 'json'; puts JSON.parse(STDIN.gets)['project']['targets'][0]")
echo $default | cat >default
echo Using default scheme: $default
- name: Build
env:
scheme: ${{ 'default' }}
platform: ${{ 'iOS Simulator' }}
run: |
device=`instruments -s -devices | grep -oE 'iPhone.*?[^\(]+' | head -1 | awk '{$1=$1;print}'`
if [ $scheme = default ]; then scheme=$(cat default); fi
if [ "`ls -A | grep -i \\.xcworkspace\$`" ]; then filetype_parameter="workspace" && file_to_build="`ls -A | grep -i \\.xcworkspace\$`"; else filetype_parameter="project" && file_to_build="`ls -A | grep -i \\.xcodeproj\$`"; fi
file_to_build=`echo $file_to_build | awk '{$1=$1;print}'`
xcodebuild build-for-testing -scheme "$scheme" -"$filetype_parameter" "$file_to_build" -destination "platform=$platform,name=$device"
- name: Test
env:
scheme: ${{ 'default' }}
platform: ${{ 'iOS Simulator' }}
run: |
device=`instruments -s -devices | grep -oE 'iPhone.*?[^\(]+' | head -1 | awk '{$1=$1;print}'`
if [ $scheme = default ]; then scheme=$(cat default); fi
if [ "`ls -A | grep -i \\.xcworkspace\$`" ]; then filetype_parameter="workspace" && file_to_build="`ls -A | grep -i \\.xcworkspace\$`"; else filetype_parameter="project" && file_to_build="`ls -A | grep -i \\.xcodeproj\$`"; fi
file_to_build=`echo $file_to_build | awk '{$1=$1;print}'`
xcodebuild test-without-building -scheme "$scheme" -"$filetype_parameter" "$file_to_build" -destination "platform=$platform,name=$device"
+9
View File
@@ -0,0 +1,9 @@
{
"name": "iOS",
"description": "Build and test an iOS application using xcodebuild and any available iPhone simulator.",
"iconName": "xcode",
"categories": [
"iOS",
"Xcode"
]
}
+1
View File
@@ -0,0 +1 @@
<svg id="Icons" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64"><defs><style>.cls-7{fill:#63b2ff}.cls-2{fill:none}.cls-2,.cls-7{stroke:#fff;stroke-miterlimit:10}.cls-3{fill:#58595b}.cls-4{fill:#939598}</style></defs><path transform="rotate(-8.8 30.61 35.43)" fill="#63b2ff" d="M3.62 14.95h54v41h-54z"/><path class="cls-2" d="M10 58L4 20M15 46l-2-13M47 41l-2-13M58 49L8 57M58 47.04l-50 8M51 13l6 38M3 22l51-8M10 37l40-7M12 44l39-7"/><path class="cls-3" d="M63.27 9.18c-2-.85-3.92-2.24-6.42-1.37a2.78 2.78 0 01-2.53-.89C52.79 4.18 50 3.48 47.48 3 36.22.88 31.55 6.65 30.34 7.74c.12.26.24.52.37.78a.61.61 0 000 .12c.68-.1 5.63-2.19 9.22.06 1.62 1 2.75 2.35 2.45 4.25a3.84 3.84 0 01-.09.44c-.06.2 0 .24-.06.45l.18.06 4.73 1.54c.07-.14.15-.35.23-.48 1.8-2.92 5.4-1.68 7.37.35 1.41 1.45 3 2 5 2.71 1.1.39 1.46-.22 1.6-.56.92-2.2 1.68-4.43 2.43-6.69a1.14 1.14 0 00-.5-1.59z"/><path class="cls-4" d="M63.27 10.33c-2-.86-3.92-2.25-6.42-1.38a2.78 2.78 0 01-2.53-.89C52.79 5.33 50 4.62 47.48 4.14 37.15 2.2 32.37 6.89 30.71 8.52a.61.61 0 000 .12c.68-.1 5.63-2.19 9.22.06 1.62 1 2.75 2.35 2.45 4.25a3.32 3.32 0 010 .95l4.73 1.54c.07-.14.15-.35.23-.48 1.8-2.92 5.4-1.68 7.37.35 1.41 1.45 3 2 5 2.71 1.1.39 1.46-.22 1.6-.56.92-2.2 1.68-4.43 2.43-6.69a1.07 1.07 0 00-.47-.44z"/><path class="cls-4" d="M42.34 13.49l-5.22 13.64 4.46 1.76 5.72-13.7-4.96-1.7z"/><path fill="#a7a9ac" d="M37.7 28.25l5.64-14.53 3.04 1.09-6.12 14.96-2.56-1.52z"/><path class="cls-3" d="M42.3 13.44l-.44 1.33c.37-1 4.49.31 5 1.56l.53-1.25c.36-1.02-4.69-2.66-5.09-1.64z"/><path d="M41.73 28.61l-11 31a2 2 0 01-2.59 1.13l-2.83-1.1a2 2 0 01-1.14-2.59L37.09 27c.14-.37.82-.4 1.63-.24C40.16 27 42 28 41.73 28.61z"/><path d="M41.73 28.61l-11 31a2 2 0 01-1.11 1.11l-2.83-1.1A2 2 0 0125.65 57l12.89-30a.39.39 0 01.18-.2c1.44.2 3.28 1.2 3.01 1.81z" fill="#231f20"/><path class="cls-7" d="M29.8 22.76l-.61-.24a2.63 2.63 0 00-3.4 1.5L18 44v7l6-5 7.3-19.84a2.63 2.63 0 00-1.5-3.4zM25.33 25.28l5.5 2.11M18.06 43.67l5.72 2.5"/></svg>

After

Width:  |  Height:  |  Size: 1.9 KiB