Skip to content

Commit f78e588

Browse files
committed
Testing
Testing Testing Testing testing Testing Testing Testing Testing Testing Testing Testing
1 parent fba2a54 commit f78e588

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

.github/workflows/build-m1-binaries.yml

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ on:
1414
workflow_dispatch:
1515
env:
1616
CHANNEL: "nightly"
17+
BASE_REF: ${{ github.base_ref }}
18+
EVENT_NAME: ${{ github.event_name }}
1719
jobs:
1820
build_wheels:
1921
name: "Build TorchVision M1 wheels"
@@ -25,12 +27,16 @@ jobs:
2527
- name: Checkout repository
2628
uses: actions/checkout@v2
2729
- name: Set CHANNEL (only for tagged pushes)
28-
if: ${{ github.event_name == 'push' && (startsWith(github.event.ref, 'refs/tags/') || startsWith(github.event.ref, 'refs/heads/release')) }}
30+
if: ${{ github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/') }}
2931
run: |
3032
# reference ends with an RC suffix
3133
if [[ ${GITHUB_REF_NAME} = *-rc[0-9]* ]]; then
3234
echo "CHANNEL=test" >> "$GITHUB_ENV"
3335
fi
36+
- name: Set Release CHANNEL (for release)
37+
if: ${{ github.event_name == 'pull_request' && startsWith(github.base_ref, 'release') }}
38+
run: |
39+
echo "CHANNEL=test" >> "$GITHUB_ENV"
3440
- name: Build TorchVision M1 wheel
3541
shell: arch -arch arm64 bash {0}
3642
env:
@@ -104,6 +110,10 @@ jobs:
104110
if [[ ${GITHUB_REF_NAME} = *-rc[0-9]* ]]; then
105111
echo "CHANNEL=test" >> "$GITHUB_ENV"
106112
fi
113+
- name: Set CHANNEL Release (for release)
114+
if: ${{ github.event_name == 'pull_request' && startsWith(github.base_ref, 'release') }}
115+
run: |
116+
echo "CHANNEL=test" >> "$GITHUB_ENV"
107117
- name: Install conda-build and purge previous artifacts
108118
shell: arch -arch arm64 bash {0}
109119
run: |
@@ -123,12 +133,19 @@ jobs:
123133
. packaging/pkg_helpers.bash
124134
125135
if [[ $CHANNEL == "test" ]]; then
136+
setup_cuda
126137
setup_base_build_version
138+
setup_macos
127139
else
140+
setup_cuda
128141
setup_build_version
142+
setup_macos
129143
fi
130144
131145
setup_conda_pytorch_constraint
146+
setup_conda_cudatoolkit_constraint
147+
setup_visual_studio_constraint
148+
setup_junit_results_folder
132149
export SOURCE_ROOT_DIR=$(pwd)
133150
conda build -c defaults $CONDA_CHANNEL_FLAGS --no-anaconda-upload --python "$PYTHON_VERSION" packaging/torchvision
134151
mkdir -p dist

0 commit comments

Comments
 (0)