You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
111 lines
2.6 KiB
111 lines
2.6 KiB
name: Build
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- '*'
|
|
pull_request:
|
|
branches:
|
|
- '*'
|
|
|
|
permissions:
|
|
contents:
|
|
write
|
|
|
|
env:
|
|
PIP_DISABLE_PIP_VERSION_CHECK: 1
|
|
|
|
defaults:
|
|
run:
|
|
shell: bash -l {0}
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Build
|
|
uses: ./.github/actions/build-dist
|
|
|
|
test:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Base Setup
|
|
uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
python -m pip install -U jupyter_packaging~=0.10
|
|
|
|
- name: Install the package
|
|
run: |
|
|
python -m pip install .
|
|
jupyter labextension list 2>&1 | grep -ie "@retrolab/lab-extension.*enabled.*ok" -
|
|
jupyter server extension list 2>&1 | grep -ie "retrolab.*enabled" -
|
|
python -m jupyterlab.browser_check
|
|
|
|
- name: Lint
|
|
run: |
|
|
jlpm
|
|
jlpm run eslint:check
|
|
jlpm run prettier:check
|
|
|
|
- name: Test
|
|
run: |
|
|
jlpm run build:test
|
|
jlpm run test
|
|
|
|
install:
|
|
needs: [build]
|
|
runs-on: ${{ matrix.os }}-latest
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
os: [ubuntu, macos, windows]
|
|
python: ['3.7', '3.10']
|
|
include:
|
|
- python: '3.7'
|
|
dist: 'retrolab*.tar.gz'
|
|
- python: '3.10'
|
|
dist: 'retrolab*.whl'
|
|
- os: windows
|
|
py_cmd: python
|
|
- os: macos
|
|
py_cmd: python3
|
|
- os: ubuntu
|
|
py_cmd: python
|
|
steps:
|
|
- name: Install Python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: ${{ matrix.python }}
|
|
architecture: 'x64'
|
|
- uses: actions/download-artifact@v2
|
|
with:
|
|
name: retrolab-dist-${{ github.run_number }}
|
|
path: ./dist
|
|
- name: Install the prerequisites
|
|
run: |
|
|
${{ matrix.py_cmd }} -m pip install pip wheel
|
|
- name: Install the package
|
|
run: |
|
|
cd dist
|
|
${{ matrix.py_cmd }} -m pip install -vv ${{ matrix.dist }}
|
|
- name: Validate environment
|
|
run: |
|
|
${{ matrix.py_cmd }} -m pip freeze
|
|
${{ matrix.py_cmd }} -m pip check
|
|
- name: Validate the install
|
|
run: |
|
|
jupyter labextension list
|
|
jupyter labextension list 2>&1 | grep -ie "@retrolab/lab-extension.*enabled.*ok" -
|
|
jupyter server extension list
|
|
jupyter server extension list 2>&1 | grep -ie "retrolab.*enabled" -
|
|
jupyter retro --version
|
|
jupyter retro --help
|