-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathproject.yml
More file actions
176 lines (168 loc) · 4.77 KB
/
project.yml
File metadata and controls
176 lines (168 loc) · 4.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
name: Trending
options:
bundleIdPrefix: com.gwikiera
groupOrdering:
- order: [Packages, Trending, TrendingUnitTests, TrendingSnapshotTests, TrendingUITests, TestPlans, Shared, Build Configs, Products]
- pattern: '^Trending.*$'
order: [AppRoot, Features, Repositories, Helpers, Generated, Resources, DevelopmentAssets]
configs:
Debug: debug
Debug-Unofficial: debug
Debug-Mock: debug
Release: release
configFiles:
Debug: Trending/Build Configs/Debug.xcconfig
Debug-Unofficial: Trending/Build Configs/Debug-Unofficial.xcconfig
Debug-Mock: Trending/Build Configs/Debug-Mock.xcconfig
Release: Trending/Build Configs/Release.xcconfig
packages:
# local packages
DesignSystem:
path: DesignSystem
Networking:
path: Networking
Model:
path: Model
GitHubAPIClient:
path: GitHubAPIClient
# remote packages
ComposableArchitecture:
url: "https://github.com/pointfreeco/swift-composable-architecture"
from: "0.51.0"
SnapshotTesting:
url: "https://github.com/pointfreeco/swift-snapshot-testing"
from: "1.11.0"
CombineSchedulers:
url: "https://github.com/pointfreeco/combine-schedulers"
from: "0.9.1"
SwiftUINavigation:
url: "https://github.com/pointfreeco/swiftui-navigation"
from: "0.6.1"
IdentifiedCollections:
url: "https://github.com/pointfreeco/swift-identified-collections"
from: "0.7.0"
PreviewSnapshots:
url: "https://github.com/doordash-oss/swiftui-preview-snapshots"
from: "1.0.0"
PreviewSnapshotsTesting:
url: "https://github.com/doordash-oss/swiftui-preview-snapshots"
from: "1.0.0"
fileGroups:
- TestPlans
targets:
Trending:
type: application
platform: iOS
dependencies:
- package: DesignSystem
- package: ComposableArchitecture
- package: Networking
- package: CombineSchedulers
- package: Model
- package: GitHubAPIClient
- package: SwiftUINavigation
- package: IdentifiedCollections
- package: PreviewSnapshots
sources: [Trending, Shared]
postCompileScripts:
- name: swiftlint
script: |
export PATH="$PATH:/opt/homebrew/bin"
if which swiftlint > /dev/null; then
swiftlint
else
echo "warning: SwiftLint not installed, download from https://github.com/realm/SwiftLint"
fi
TrendingUnitTests:
type: bundle.unit-test
platform: iOS
sources:
- path: TrendingUnitTests
includes:
- "**/*.swift"
dependencies:
- target: Trending
settings:
# makes xcode use the only target as host app
- TEST_HOST: ""
TrendingSnapshotTests:
type: bundle.unit-test
platform: iOS
sources:
- path: TrendingSnapshotTests
includes:
- "**/*SnapshotTests.swift"
excludes:
- "**/test*.png"
- "**/__Snapshots__"
dependencies:
- target: Trending
- package: SnapshotTesting
- package: PreviewSnapshotsTesting
settings:
# makes xcode use the only target as host app
- TEST_HOST: ""
TrendingUITests:
type: bundle.ui-testing
platform: iOS
sources:
- path: TrendingUITests
includes:
- "**/*.swift"
- path: Shared
includes:
- "**/*.swift"
dependencies:
- target: Trending
schemes:
Trending:
templates:
- TrendingScheme
templateAttributes:
configName: Debug
Trending-Unofficial:
templates:
- TrendingScheme
templateAttributes:
configName: Debug-Unofficial
Trending-Mock:
templates:
- TrendingScheme
templateAttributes:
configName: Debug-Mock
schemeTemplates:
TrendingScheme:
build:
targets:
Trending: [run, test, profile, analyze]
preActions:
- name: swiftgen
script: |
if [[ -z "$CI" ]]; then
RUNNING_ON_CI=false
else
RUNNING_ON_CI=$CI
fi
if [[ "$RUNNING_ON_CI" = false ]]; then
export SWIFTGEN_PATH="${HOMEBREW_PREFIX}/bin/swiftgen"
if which "${SWIFTGEN_PATH}" >/dev/null; then
"${SWIFTGEN_PATH}" config run --config ${SRCROOT}/swiftgen.yml
else
echo "Warning: SwiftGen not installed"
fi
else
echo 'SwiftGen disabled for CI.'
fi
settingsTarget: "Trending"
run:
config: ${configName}
test:
config: ${configName}
testPlans:
- path: TestPlans/UnitTests.xctestplan
- path: TestPlans/AllTests.xctestplan
defaultPlan: true
profile:
config: Release
analyze:
config: Release