Skip to content

Commit 87d58cd

Browse files
authored
Update step.yml (#298)
* Update step.yml * Update README.md * Pull latest go-xcode/v2 * Update step.yml
1 parent c55aa3e commit 87d58cd

File tree

7 files changed

+25
-17
lines changed

7 files changed

+25
-17
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,9 @@ Build a development IPA with custom xcconfig file path:
110110
| `scheme` | Xcode Scheme name. The input value sets xcodebuild's `-scheme` option. | required | `$BITRISE_SCHEME` |
111111
| `distribution_method` | Describes how Xcode should export the archive. | required | `development` |
112112
| `configuration` | Xcode Build Configuration. If not specified, the default Build Configuration will be used. The input value sets xcodebuild's `-configuration` option. | | |
113-
| `xcconfig_content` | Build settings to override the project's build settings, using xcodebuild's `-xcconfig` option. If empty, no setting is changed. This is required when the `-xcconfig` additional option is used. When set it can be either: 1. Existing `.xcconfig` file path. Example: `./ios-sample/ios-sample/Configurations/Dev.xcconfig` 2. The contents of a newly created temporary `.xcconfig` file. (This is the default.) Build settings must be separated by newline character (`\n`). Example: ``` COMPILER_INDEX_STORE_ENABLE = NO ONLY_ACTIVE_ARCH[config=Debug][sdk=*][arch=*] = YES ``` | | `COMPILER_INDEX_STORE_ENABLE = NO` |
113+
| `xcconfig_content` | Build settings to override the project's build settings, using xcodebuild's `-xcconfig` option. You can't define `-xcconfig` option in `Additional options for the xcodebuild command` if this input is set. If empty, no setting is changed. When set it can be either: 1. Existing `.xcconfig` file path. Example: `./ios-sample/ios-sample/Configurations/Dev.xcconfig` 2. The contents of a newly created temporary `.xcconfig` file. (This is the default.) Build settings must be separated by newline character (`\n`). Example: ``` COMPILER_INDEX_STORE_ENABLE = NO ONLY_ACTIVE_ARCH[config=Debug][sdk=*][arch=*] = YES ``` | | `COMPILER_INDEX_STORE_ENABLE = NO` |
114114
| `perform_clean_action` | If this input is set, `clean` xcodebuild action will be performed besides the `archive` action. | required | `no` |
115-
| `xcodebuild_options` | Additional options to be added to the executed xcodebuild command. | | |
115+
| `xcodebuild_options` | Additional options to be added to the executed xcodebuild command. Prefer using `Build settings (xcconfig)` input for specifying `-xcconfig` option. You can't use both. `-destination` is set automatically, unless specified explicitely. | | |
116116
| `log_formatter` | Defines how `xcodebuild` command's log is formatted. Available options: - `xcpretty`: The xcodebuild command's output will be prettified by xcpretty. - `xcodebuild`: Only the last 20 lines of raw xcodebuild output will be visible in the build log. The raw xcodebuild log will be exported in both cases. | required | `xcpretty` |
117117
| `automatic_code_signing` | This input determines which Bitrise Apple service connection should be used for automatic code signing. Available values: - `off`: Do not do any auto code signing. - `api-key`: [Bitrise Apple Service connection with API Key](https://devcenter.bitrise.io/getting-started/connecting-to-services/setting-up-connection-to-an-apple-service-with-api-key/). - `apple-id`: [Bitrise Apple Service connection with Apple ID](https://devcenter.bitrise.io/getting-started/connecting-to-services/connecting-to-an-apple-service-with-apple-id/). | required | `off` |
118118
| `register_test_devices` | If this input is set, the Step will register the known test devices on Bitrise from team members with the Apple Developer Portal. Note that setting this to yes may cause devices to be registered against your limited quantity of test devices in the Apple Developer Portal, which can only be removed once annually during your renewal window. | required | `no` |

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ require (
77
github.com/bitrise-io/go-utils v1.0.2
88
github.com/bitrise-io/go-utils/v2 v2.0.0-alpha.7
99
github.com/bitrise-io/go-xcode v1.0.8
10-
github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.16
10+
github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.17
1111
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51
1212
github.com/stretchr/testify v1.7.1
1313
golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e // indirect

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ github.com/bitrise-io/go-utils/v2 v2.0.0-alpha.7/go.mod h1:6i0Gt0JRIbXpsrFDJT1YW
1414
github.com/bitrise-io/go-xcode v1.0.6/go.mod h1:Y0Wu2dXm0MilJ/4D3+gPHaNMlUcP+1DjIPoLPykq7wY=
1515
github.com/bitrise-io/go-xcode v1.0.8 h1:fNB5TmbfsqWRh5ibtKdFdxPEua8gaNBmDt1rPM/GDuo=
1616
github.com/bitrise-io/go-xcode v1.0.8/go.mod h1:Y0Wu2dXm0MilJ/4D3+gPHaNMlUcP+1DjIPoLPykq7wY=
17-
github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.16 h1:tJGx3Ly0UclO1oDEiW1W+DYL9UQQwPJ11sgJ/Z917rw=
18-
github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.16/go.mod h1:oYILBt4j8jn69avylknuqsUO/BSiRx9i+JaxcNOtWMA=
17+
github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.17 h1:aLlblow6vgnFKBRJRPz03O/M6x6LYY57wDkRCh66XL0=
18+
github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.17/go.mod h1:oYILBt4j8jn69avylknuqsUO/BSiRx9i+JaxcNOtWMA=
1919
github.com/bitrise-io/pkcs12 v0.0.0-20211108084543-e52728e011c8 h1:kmvU8AxrNTxXsVPKepBHD8W+eCVmeaKyTkRuUJB2K38=
2020
github.com/bitrise-io/pkcs12 v0.0.0-20211108084543-e52728e011c8/go.mod h1:UiXKNs0essbC14a2TvGlnUKo9isP9m4guPrp8KJHJpU=
2121
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=

main.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,7 @@ type XcodeArchiveStep struct {
207207
stepInputParser stepconf.InputParser
208208
pathProvider pathutil.PathProvider
209209
pathChecker pathutil.PathChecker
210+
pathModifier pathutil.PathModifier
210211
fileManager fileutil.FileManager
211212
}
212213

@@ -217,6 +218,7 @@ func NewXcodeArchiveStep() XcodeArchiveStep {
217218
stepInputParser: stepconf.NewInputParser(env.NewRepository()),
218219
pathProvider: pathutil.NewPathProvider(),
219220
pathChecker: pathutil.NewPathChecker(),
221+
pathModifier: pathutil.NewPathModifier(),
220222
fileManager: fileutil.NewFileManager(),
221223
}
222224
}
@@ -526,7 +528,7 @@ func (s XcodeArchiveStep) xcodeArchive(opts xcodeArchiveOpts) (xcodeArchiveOutpu
526528
}
527529

528530
if opts.XcconfigContent != "" {
529-
xcconfigWriter := xcconfig.NewWriter(s.pathProvider, s.fileManager, s.pathChecker)
531+
xcconfigWriter := xcconfig.NewWriter(s.pathProvider, s.fileManager, s.pathChecker, s.pathModifier)
530532
xcconfigPath, err := xcconfigWriter.Write(opts.XcconfigContent)
531533
if err != nil {
532534
return out, fmt.Errorf("failed to write xcconfig file contents: %w", err)

step.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -120,13 +120,13 @@ inputs:
120120
opts:
121121
category: xcodebuild configuration
122122
title: Build settings (xcconfig)
123-
summary: Build settings to override the project's build settings. Can be the contents, file path or empty.
123+
summary: Build settings to override the project's build settings, using xcodebuild's `-xcconfig` option.
124124
description: |-
125125
Build settings to override the project's build settings, using xcodebuild's `-xcconfig` option.
126126
127-
If empty, no setting is changed. This is required when the `-xcconfig` additional option is used.
127+
You can't define `-xcconfig` option in `Additional options for the xcodebuild command` if this input is set.
128128
129-
When set it can be either:
129+
If empty, no setting is changed. When set it can be either:
130130
1. Existing `.xcconfig` file path.
131131
132132
Example:
@@ -157,11 +157,11 @@ inputs:
157157
opts:
158158
category: xcodebuild configuration
159159
title: Additional options for the xcodebuild command
160-
description: Additional options to be added to the executed xcodebuild command.
161-
summary: |-
160+
summary: Additional options to be added to the executed xcodebuild command.
161+
description: |-
162162
Additional options to be added to the executed xcodebuild command.
163163
164-
When setting the `-xcconfig` option, makes sure to clear the "Build settings (xcconfig)" input, as can not specify both.
164+
Prefer using `Build settings (xcconfig)` input for specifying `-xcconfig` option. You can't use both.
165165
166166
`-destination` is set automatically, unless specified explicitely.
167167

vendor/github.com/bitrise-io/go-xcode/v2/xcconfig/xcconfig.go

Lines changed: 10 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/modules.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ github.com/bitrise-io/go-xcode/xcodeproject/xcodeproj
5454
github.com/bitrise-io/go-xcode/xcodeproject/xcscheme
5555
github.com/bitrise-io/go-xcode/xcodeproject/xcworkspace
5656
github.com/bitrise-io/go-xcode/xcpretty
57-
# github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.16
57+
# github.com/bitrise-io/go-xcode/v2 v2.0.0-alpha.17
5858
## explicit
5959
github.com/bitrise-io/go-xcode/v2/autocodesign
6060
github.com/bitrise-io/go-xcode/v2/autocodesign/certdownloader

0 commit comments

Comments
 (0)