use input registry for fieldsets #198
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Package Tests | |
on: [push, pull_request] | |
jobs: | |
npm: | |
name: "@wq/${{ matrix.package }}" | |
runs-on: ubuntu-20.04 | |
env: | |
PACKAGE: ${{ matrix.package }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.10"] | |
node-version: [18] | |
package: | |
- app | |
- model | |
- outbox | |
- router | |
- store | |
- react | |
- material | |
- material-web | |
- material-native | |
- map | |
- map-gl | |
- map-gl-web | |
- map-gl-native | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up Node ${{ matrix.node-version }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: npm ci && npm run build | |
- name: Install native dependencies | |
if: matrix.package == 'material-native' || matrix.package == 'map-gl-native' | |
run: cd packages/$PACKAGE && npm ci | |
- name: Lint with ESLint | |
run: npm run lint | |
- name: Check ESM Imports | |
run: | | |
echo 'export default "0.0.0";' > version.js | |
sed -i "s/@mui\/material\/utils\/index.js/@mui\/material\/node\/utils\/index.js/" modules.js | |
node index.js | |
git checkout modules.js | |
- name: Start test server | |
run: python -m tests.server & | |
- name: Test with Jest | |
run: | | |
cd packages/$PACKAGE | |
npm run test | |
- uses: smartsquaregmbh/[email protected] | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
with: | |
keep: 5 | |
names: ${{ matrix.package }} | |
- name: Publish to Github Packages | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
run: | | |
python -m pip install setuptools_scm | |
./set_dev_version.sh | |
echo "registry=https://npm.pkg.github.com/wq" > .npmrc | |
echo "//npm.pkg.github.com/:_authToken=${{ secrets.GITHUB_TOKEN }}" >> .npmrc | |
cp .npmrc packages/$PACKAGE/.npmrc # for native builds | |
cd packages/$PACKAGE | |
npm publish | |
pip: | |
name: Python Package | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: | |
python-version: ["3.11"] | |
node-version: [18] | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Set up Node ${{ matrix.python-node }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
python -m pip install build | |
- name: Build Python Wheel | |
run: | | |
python -m build | |
python -m pip install `ls dist/*.whl` | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: wq.app | |
path: dist/*.whl |