Skip to content

Commit 4a199fd

Browse files
authored
feat: allow passing executor parameters to jobs (#133)
1 parent 1f4e591 commit 4a199fd

File tree

2 files changed

+31
-4
lines changed

2 files changed

+31
-4
lines changed

src/jobs/android_build.yml

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
description: Builds the Android app at the given path with the given build types.
22

3-
executor: linux_android
4-
53
parameters:
64
# For this job
75
checkout:
@@ -49,6 +47,24 @@ parameters:
4947
description: Configure the android tests to run. Defaults to assembleAndroidTest
5048
type: string
5149
default: assembleAndroidTest
50+
java_options:
51+
description: Java command options. Note that setting this will override the default options so you might need to supply those as well.
52+
type: string
53+
default: '-Xmx1024m -XX:+UnlockExperimentalVMOptions -XX:+UseContainerSupport'
54+
gradle_options:
55+
description: Gradle command options. Note that setting this will override the default options so you might need to supply those as well.
56+
type: string
57+
default: '-Xmx2014m -Dorg.gradle.daemon=false -Dorg.gradle.jvmargs="-XX:+UnlockExperimentalVMOptions -XX:+HeapDumpOnOutOfMemoryError"'
58+
resource_class:
59+
description: Changes the resource class of the executor. Requires a support request to enable the resource_class parameter. See https://circleci.com/docs/2.0/configuration-reference/#resource_class
60+
type: string
61+
default: medium
62+
63+
executor:
64+
name: linux_android
65+
java_options: <<parameters.java_options>>
66+
gradle_options: <<parameters.gradle_options>>
67+
resource_class: <<parameters.resource_class>>
5268

5369
steps:
5470
- when:

src/jobs/ios_build.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
description: Builds the iOS app at the given path with the given build scheme
22

3-
executor: macos
4-
53
parameters:
64
# For this job
75
checkout:
@@ -77,6 +75,19 @@ parameters:
7775
description: Should we run brew update? Defaults to true
7876
type: boolean
7977
default: true
78+
xcode_version:
79+
description: The version of Xcode to use. See here for the list of supported versions https://circleci.com/docs/2.0/testing-ios/#supported-xcode-versions
80+
type: string
81+
default: "12.4.0"
82+
resource_class:
83+
description: Changes the resource class of the executor. Requires a support request to enable the resource_class parameter. See https://circleci.com/docs/2.0/configuration-reference/#resource_class
84+
type: string
85+
default: medium
86+
87+
executor:
88+
name: macos
89+
xcode_version: <<parameters.xcode_version>>
90+
resource_class: <<parameters.resource_class>>
8091

8192
steps:
8293
- when:

0 commit comments

Comments
 (0)