Skip to content

Commit 8db7687

Browse files
author
dbort
committed
Add submodule input for build_wheels_*.yaml
Let users of `build_wheels_*.yml` override the `submodules` input of `setup-binary-build`. pytorch/executorch does not need (or want) to do a full recursive submodule checkout.
1 parent 3f267e6 commit 8db7687

File tree

3 files changed

+21
-3
lines changed

3 files changed

+21
-3
lines changed

.github/workflows/build_wheels_linux.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,13 +60,18 @@ on:
6060
required: false
6161
type: string
6262
default: x86_64
63-
setup-miniconda:
63+
submodules:
6464
description: Works as stated in actions/checkout, but the default value is recursive
6565
required: false
66+
type: string
67+
default: recursive
68+
setup-miniconda:
69+
description: Set to true if setup-miniconda is needed
70+
required: false
6671
type: boolean
6772
default: true
6873
build-platform:
69-
description: Platform to build wheels, choose from 'python-build-package' or 'setup-py'
74+
description: Platform to build wheels, choose from 'python-build-package' or 'setup-py'
7075
required: false
7176
type: string
7277
default: 'setup-py'
@@ -147,6 +152,7 @@ jobs:
147152
with:
148153
repository: ${{ inputs.repository }}
149154
ref: ${{ inputs.ref }}
155+
submodules: ${{ inputs.submodules }}
150156
setup-miniconda: ${{ inputs.setup-miniconda }}
151157
python-version: ${{ env.PYTHON_VERSION }}
152158
cuda-version: ${{ env.CU_VERSION }}
@@ -184,7 +190,7 @@ jobs:
184190
echo "Successfully installed Python build package"
185191
${CONDA_RUN} python -m build --wheel
186192
- name: Build the wheel (setup-py)
187-
if: ${{ inputs.build-platform == 'setup-py' }}
193+
if: ${{ inputs.build-platform == 'setup-py' }}
188194
working-directory: ${{ inputs.repository }}
189195
shell: bash -l {0}
190196
run: |

.github/workflows/build_wheels_macos.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,11 @@ on:
5959
description: "The key created when saving a cache and the key used to search for a cache."
6060
default: ""
6161
type: string
62+
submodules:
63+
description: "Works as stated in actions/checkout, but the default value is recursive"
64+
required: false
65+
type: string
66+
default: recursive
6267

6368
permissions:
6469
id-token: write
@@ -105,6 +110,7 @@ jobs:
105110
with:
106111
repository: ${{ inputs.repository }}
107112
ref: ${{ inputs.ref }}
113+
submodules: ${{ inputs.submodules }}
108114
setup-miniconda: false
109115
python-version: ${{ env.PYTHON_VERSION }}
110116
cuda-version: ${{ env.CU_VERSION }}

.github/workflows/build_wheels_windows.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,11 @@ on:
5959
description: "The key created when saving a cache and the key used to search for a cache."
6060
default: ""
6161
type: string
62+
submodules:
63+
description: "Works as stated in actions/checkout, but the default value is recursive"
64+
required: false
65+
type: string
66+
default: recursive
6267

6368
permissions:
6469
id-token: write
@@ -111,6 +116,7 @@ jobs:
111116
with:
112117
repository: ${{ inputs.repository }}
113118
ref: ${{ inputs.ref }}
119+
submodules: ${{ inputs.submodules }}
114120
setup-miniconda: false
115121
python-version: ${{ env.PYTHON_VERSION }}
116122
cuda-version: ${{ env.CU_VERSION }}

0 commit comments

Comments
 (0)