This repository has been archived by the owner on May 18, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
98 lines (95 loc) · 2.55 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: Build
on:
push:
branches: master
tags: 'v*'
pull_request:
branches: '*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install node
uses: actions/setup-node@v1
with:
node-version: '10.x'
- name: Install Python
uses: actions/setup-python@v1
with:
python-version: '3.7'
architecture: 'x64'
- name: Install Python dependencies
run: |
python -m pip install jupyterlab
python -m pip install -r requirements.txt
- name: Run Pytest
run: pytest rucio_jupyterlab/tests/
- name: Run Pylint
run: pylint-fail-under --fail_under 8.5 rucio_jupyterlab/
- name: Install JS dependencies
run: jlpm
- name: Run ESLint
run: jlpm run eslint:check
- name: Run Jest
run: jlpm jest
- name: Build the extension
run: |
pip install .
jupyter lab build
jupyter serverextension list 1>serverextensions 2>&1
cat serverextensions | grep "rucio_jupyterlab.*OK"
jupyter labextension list 1>labextensions 2>&1
cat labextensions | grep "rucio-jupyterlab.*OK"
python -m jupyterlab.browser_check
docker:
name: Build Docker image
if: github.event_name == 'push'
needs: build
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Publish to Registry
uses: docker/build-push-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
repository: didithilmy/rucio-jupyterlab
tag_with_ref: true
publish:
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
needs: build
name: Publish extension to PyPI
runs-on: ubuntu-18.04
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Set up Python 3.7
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Install node
uses: actions/setup-node@v1
with:
node-version: '10.x'
- name: Install build requirements
run: >-
python -m
pip install
pep517 jupyter_packaging
--user
- name: Build a binary wheel and a source tarball
run: >-
python -m
pep517.build
--source
--binary
--out-dir dist/
.
- name: Publish distribution to PyPI
uses: pypa/gh-action-pypi-publish@master
with:
password: ${{ secrets.pypi_password }}
skip_existing: true