Skip to content

Commit

Permalink
Add more inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
ffried committed Oct 2, 2023
1 parent 46af455 commit 77747b9
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 147 deletions.
147 changes: 1 addition & 146 deletions README.md
Expand Up @@ -8,152 +8,7 @@ Note that this action needs to run on macOS. All other platforms will fail!

## Inputs

### `workspace`

The path to the xcworkspace to build. Mutually exclusive with `project` and `spm-package`. Either `workspace`, `project` or `spm-package` must be set. See also `xcodebuild`'s `-workspace`.

### `project`

The path to the xcodeproj to build. Mutually exclusive with `workspace` and `spm-package`. Either `workspace`, `project` or `spm-package` must be set. See also `xcodebuild`'s `-project`.

### `spm-package`

The path to the SPM package (folder containing `Package.swift`) to build. Mutually exclusive with `project` and `workspace`. Either `workspace`, `project` or `spm-package` must be set.

### `scheme`

The scheme to build. Required when using a workspace or SPM package. See also `xcodebuild`'s `-scheme`.

### `target`

The target to build. See also `xcodebuild`'s `-target`.

### `destination`

The destination specifier to build. See also `xcodebuild`'s `-destination`.

### `configuration`

The configuration to build. See also `xcodebuild`'s `-configuration`.

### `sdk`

The SDK to use for building. See also `xcodebuild`'s `-sdk`.

### `arch`

The architecture to use for building. See also `xcodebuild`'s `-arch`.

### `xcconfig`

The path to an xcconfig file with build settings overrides. See also `xcodebuild`'s `-xcconfig`.

### `jobs`

The number of jobs to use for building. See also `xcodebuild`'s `-jobs`.

### `parallelize-targets`

If `true`, the targets will be built in parallel. See also `xcodebuild`'s `-parallelizeTargets`.

### `quiet`

If `true`, `xcodebuild` won't print anything except warnings and errors. See also `xcodebuild`'s `-quiet`.

### `hide-shell-script-environment`

If `true`, `xcodebuild` won't print the environment for shell build scripts. See also `xcodebuild`'s `-hideShellScriptEnvironment`.

### `enable-code-coverage`

If `true`, code coverage is enabled while testing. See also `xcodebuild`'s `-enableCodeCoverage`.

### `parallel-testing-enabled`

If `true`, tests are executed in parallel. See also `xcodebuild`'s `-parallel-testing-enabled`.

### `maximum-concurrent-test-device-destinations`

The maximum number of device destinations to run in parallel. See also `xcodebuild`'s `-maximum-concurrent-test-device-destinations`.

### `maximum-concurrent-test-simulator-destinations`

The maximum number of simulator destinations to run in parallel. See also `xcodebuild`'s `-maximum-concurrent-test-simulator-destinations`.

### `enable-address-sanitizer`

Whether the address sanitizer should be enabled. See also `xcodebuild`'s `-enableAddressSanitizer`.

### `enable-thread-sanitizer`

Whether the thread sanitizer should be enabled. See also `xcodebuild`'s `-enableThreadSanitizer`.

### `enable-undefined-behavior-sanitizer`

Whether the undefined behavior sanitizer should be enabled. See also `xcodebuild`'s `-enableUndefinedBehaviorSanitizer`.

### `result-bundle-path`

The path that should be used for the result bundle. See also `xcodebuild`'s `-resultBundlePath`.

### `result-bundle-version`

The version that should be used for the result bundle. See also `xcodebuild`'s `-resultBundleVersion`.

### `cloned-source-packages-path`

The path that should be used for the cloning of remote packages. See also `xcodebuild`'s `-clonedSourcePackagesDirPath`.

### `derived-data-path`

The path that should be used for derived data. See also `xcdodebuild`'s `-derivedDataPath`.

### `xcroot`

The path to a .xcroot to use for building and/or testing. See also `xcodebuild`'s `-xcroot`.

### `xctestrun`

The path to a test run specification. See also `xcodebuild`'s `-xctestrun`.

### `test-plan`

The name of the test plan associated with the scheme to use for testing. See also `xcodebuild`'s `-testPlan`.

### `only-testing`

A list of tests to run. This can be multiline list of test identifiers. See also `xcodebuild`'s `-only-testing`.

### `skip-testing`

A list of tests to skip. This can be multiline list of test identifiers. See also `xcodebuild`'s `-only-testing`.

### `skip-unavailable-actions`

Whether unavailable actions should be skipped instead of failing the execution. See also `xcodebuild`'s `-skipUnavailableActions`.

### `allow-provisioning-updates`

Whether provisioning updates are allowed. See also `xcodebuild`'s `-allowProvisioningUpdates`.

### `allow-provisioning-device-registration`

Whether provisioning device registrations are allowed. See also `xcodebuild`'s `-allowProvisioningDeviceRegistration`.

### `build-settings`

Arbitrary, space separated build settings (e.g. `PLATFORM_NAME=iphonesimulator`).

### `action`

The action to perform (e.g. build, test, ...). Can also contain multiple actions.<br/>
Default: `test`

### `output-formatter`

A CLI invocation to forward the output to (e.g. `xcpretty`, `xcbeautify`, ...). Note that it cannot contain any pipes.<br/>
Default: `xcpretty --color`

See [action.yml](action.yml) for an overview of all inputs.

## Outputs

Expand Down
18 changes: 18 additions & 0 deletions action.yml
Expand Up @@ -74,9 +74,27 @@ inputs:
cloned-source-packages-path:
description: The path that should be used for the cloning of remote packages. See also `xcodebuild`'s `-clonedSourcePackagesDirPath`.
required: false
package-cache-path:
description: The path of caches used for package support. See also `xcodebuild`'s `-packageCachePath`.
required: false
derived-data-path:
description: The path that should be used for derived data. See also `xcodebuild`'s `-derivedDataPath`.
required: false
disable-package-repository-cache:
description: Whether the package repository cache should be disabled. See also `xcodebuild`'s `-disablePackageRepositoryCache`.
required: false
disable-automatic-package-resolution:
description: Whether automatic package resolution should be disabled. See also `xcodebuild`'s `-disableAutomaticPackageResolution`.
required: false
skip-package-updates:
description: Whether package updates should be skipped. See also `xcodebuild`'s `-skipPackageUpdates`.
required: false
skip-package-plugin-validation:
description: Whether package plugin validation should be skipped. See also `xcodebuild`'s `-skipPackagePluginValidation`.
required: false
skip-macro-validation:
description: Whether macro validation should be skipped. See also `xcodebuild`'s `-skipMacroValidation`.
required: false
xcroot:
description: The path to a .xcroot to use for building and/or testing. See also `xcodebuild`'s `-xcroot`.
required: false
Expand Down
8 changes: 7 additions & 1 deletion src/main.ts
Expand Up @@ -68,7 +68,7 @@ function argumentStrings(argument: ICommandArgument,
useResolvedValue: boolean = true,
escapeValue: boolean = false): string[] {
let plain = [argument.name];
if (argument.value)
if (argument.value)
plain.push(argumentValueString(argument.value, useResolvedValue, escapeValue));
return plain;
}
Expand Down Expand Up @@ -224,7 +224,13 @@ async function main() {
addPathArg('result-bundle-path', 'resultBundlePath');
addInputArg('result-bundle-version', 'resultBundleVersion');
addPathArg('cloned-source-packages-path', 'clonedSourcePackagesDirPath');
addPathArg('package-cache-path', 'packageCachePath');
addPathArg('derived-data-path', 'derivedDataPath');
addFlagArg('disable-package-repository-cache', 'disablePackageRepositoryCache');
addFlagArg('disable-automatic-package-resolution', 'disableAutomaticPackageResolution');
addFlagArg('skip-package-updates', 'skipPackageUpdates');
addFlagArg('skip-package-plugin-validation', 'skipPackagePluginValidation');
addFlagArg('skip-macro-validation', 'skipMacroValidation');
addPathArg('xcroot');
addPathArg('xctestrun');
addInputArg('test-plan', 'testPlan');
Expand Down

0 comments on commit 77747b9

Please sign in to comment.