Skip to content

Commit

Permalink
ci: ignore build if cached
Browse files Browse the repository at this point in the history
  • Loading branch information
hans00 committed Jun 2, 2024
1 parent 4c2ba5d commit b711e09
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,23 +29,25 @@ jobs:
uses: actions/cache@v2
with:
path: executorch/cmake-out
key: ${{ runner.os }}-cmake-${{ hashFiles('executorch/CMakeLists.txt') }}
key: ${{ runner.os }}-cmake-${{ hashFiles('executorch/kernels/*.cpp') }}-${{ hashFiles('executorch/extension/*.cpp') }}-${{ hashFiles('executorch/backends/*.cpp') }}-${{ hashFiles('executorch/runtime/*.cpp') }}
- name: Build executorch
run: |
python -m venv .venv
source .venv/bin/activate
cd executorch
pip install tomli zstd setuptools wheel
pip install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cpu
./install_requirements.sh
cmake \
-S . \
-B cmake-out \
-DCMAKE_INSTALL_PREFIX=cmake-out \
-DEXECUTORCH_BUILD_XNNPACK=ON \
-DEXECUTORCH_BUILD_EXTENSION_DATA_LOADER=ON \
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON
cmake --build cmake-out --target install --config Release
if [ ! -d cmake-out ]; then
./install_requirements.sh
cmake \
-S . \
-B cmake-out \
-DCMAKE_INSTALL_PREFIX=cmake-out \
-DEXECUTORCH_BUILD_XNNPACK=ON \
-DEXECUTORCH_BUILD_EXTENSION_DATA_LOADER=ON \
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON
cmake --build cmake-out --target install --config Release
fi
- name: Install dependencies
run: yarn install
- name: Build
Expand Down

0 comments on commit b711e09

Please sign in to comment.