Skip to content

Commit

Permalink
Simplify CI setup
Browse files Browse the repository at this point in the history
  • Loading branch information
martinRenou committed Jan 15, 2025
1 parent a71c8be commit 386bb3c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 54 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/deploy-github-page.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ name: Build and Deploy

on:
workflow_dispatch:
pull_request:
push:
branches:
- main
Expand Down Expand Up @@ -82,12 +83,15 @@ jobs:

deploy:
needs: build
if: github.ref == 'refs/heads/main'
permissions:
pages: write
id-token: write

environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}

runs-on: ubuntu-24.04
steps:
- name: Deploy to GitHub Pages
Expand Down
58 changes: 4 additions & 54 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ on:

jobs:
unix:

runs-on: ${{ matrix.os }}

strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -55,11 +55,11 @@ jobs:
run: |
cd test
pytest . --reruns 5
win:

runs-on: ${{ matrix.os }}

strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -113,53 +113,3 @@ jobs:
call C:\Users\runneradmin\micromamba-root\condabin\micromamba.bat activate xeus-r
cd test
pytest -sv test_xr_kernel.py
emscripten_wasm:

runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
emsdk_ver: ["3.1.45"]

steps:
- uses: actions/checkout@v4

- name: Install mamba
uses: mamba-org/setup-micromamba@v2
with:
environment-file: environment-wasm-build.yml
environment-name: xeus-r-wasm-build

- name: Build xeus-r
shell: bash -l {0}
run: |
micromamba create -f environment-wasm-host.yml --platform=emscripten-wasm32
mkdir build
pushd build
export EMPACK_PREFIX=$MAMBA_ROOT_PREFIX/envs/xeus-r-wasm-build
export PREFIX=$MAMBA_ROOT_PREFIX/envs/xeus-r-wasm-host
echo "PREFIX=$PREFIX" >> $GITHUB_ENV
export CMAKE_PREFIX_PATH=$PREFIX
export CMAKE_SYSTEM_PREFIX_PATH=$PREFIX
emcmake cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_PREFIX_PATH=$PREFIX \
-DCMAKE_INSTALL_PREFIX=$PREFIX \
-DXEUS_R_EMSCRIPTEN_WASM_BUILD=ON \
-DCMAKE_FIND_ROOT_PATH_MODE_PACKAGE=ON \
..
emmake make install
- name: Jupyter Lite integration
shell: bash -l {0}
run: |
micromamba create -n xeus-lite-host jupyterlite-core
micromamba activate xeus-lite-host
python -m pip install jupyterlite-xeus
jupyter lite build --XeusAddon.prefix=${{ env.PREFIX }}

0 comments on commit 386bb3c

Please sign in to comment.