Skip to content

Commit dd5167f

Browse files
committed
[ci] Move to GitHub Actions
1 parent 908e38d commit dd5167f

File tree

4 files changed

+147
-36
lines changed

4 files changed

+147
-36
lines changed

.github/workflows/deloy.yml

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Upload PyPi Package
2+
3+
on:
4+
push:
5+
branches:
6+
- develop
7+
- develop-**
8+
9+
jobs:
10+
deploy:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v2
14+
- name: Set up Python
15+
uses: actions/setup-python@v2
16+
with:
17+
python-version: '3.x'
18+
- name: Install dependencies
19+
run: |
20+
python -m pip install --upgrade pip
21+
pip install lxml jinja2 deepdiff CppHeaderParser setuptools wheel twine
22+
- name: Build and publish
23+
env:
24+
TWINE_USERNAME: __token__
25+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
26+
run: |
27+
python setup.py sdist bdist_wheel
28+
twine upload --skip-existing dist/*

.github/workflows/tests.yml

+119
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,119 @@
1+
name: Generate
2+
3+
on:
4+
schedule:
5+
- cron: '23 7 * * *'
6+
pull_request:
7+
8+
env:
9+
MAKEFLAGS: -j4
10+
11+
jobs:
12+
stm32-f4-g4-l0:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v2
16+
- name: Set up Python
17+
uses: actions/setup-python@v2
18+
with:
19+
python-version: '3.x'
20+
- name: Install dependencies
21+
run: |
22+
python -m pip install --upgrade pip
23+
pip install lxml jinja2 deepdiff CppHeaderParser
24+
- name: Generate STM32 data
25+
run: |
26+
cd tools/generator
27+
make generate-stm32f4 generate-stm32g4 generate-stm32l0
28+
- name: Synchronize Docs
29+
run: |
30+
python3 tools/scripts/sync_docs.py
31+
git diff -- README.md
32+
git status --porcelain
33+
git diff $(git diff --name-only | sed -n 1p)
34+
(( $(git status --porcelain | wc -l) == 0 ))
35+
36+
stm32-g0-h7-l4:
37+
runs-on: ubuntu-latest
38+
steps:
39+
- uses: actions/checkout@v2
40+
- name: Set up Python
41+
uses: actions/setup-python@v2
42+
with:
43+
python-version: '3.x'
44+
- name: Install dependencies
45+
run: |
46+
python -m pip install --upgrade pip
47+
pip install lxml jinja2 deepdiff CppHeaderParser
48+
- name: Generate STM32 data
49+
run: |
50+
cd tools/generator
51+
make generate-stm32g0 generate-stm32h7 generate-stm32l4
52+
- name: Synchronize Docs
53+
run: |
54+
python3 tools/scripts/sync_docs.py
55+
git diff -- README.md
56+
git status --porcelain
57+
git diff $(git diff --name-only | sed -n 1p)
58+
(( $(git status --porcelain | wc -l) == 0 ))
59+
60+
stm32-f0-f1-f2-f3-f7-l1-wb-wl:
61+
runs-on: ubuntu-latest
62+
steps:
63+
- uses: actions/checkout@v2
64+
- name: Set up Python
65+
uses: actions/setup-python@v2
66+
with:
67+
python-version: '3.x'
68+
- name: Install dependencies
69+
run: |
70+
python -m pip install --upgrade pip
71+
pip install lxml jinja2 deepdiff CppHeaderParser
72+
- name: Generate STM32 data
73+
run: |
74+
cd tools/generator
75+
make generate-stm32f0 generate-stm32f1 generate-stm32f2 generate-stm32f3 \
76+
generate-stm32f7 generate-stm32l1 generate-stm32wb generate-stm32wl
77+
- name: Synchronize Docs
78+
run: |
79+
python3 tools/scripts/sync_docs.py
80+
git diff -- README.md
81+
git status --porcelain
82+
git diff $(git diff --name-only | sed -n 1p)
83+
(( $(git status --porcelain | wc -l) == 0 ))
84+
85+
avr-sam-ndf:
86+
runs-on: ubuntu-latest
87+
steps:
88+
- uses: actions/checkout@v2
89+
- name: Set up Python
90+
uses: actions/setup-python@v2
91+
with:
92+
python-version: '3.x'
93+
- name: Install dependencies
94+
run: |
95+
python -m pip install --upgrade pip
96+
pip install lxml jinja2 deepdiff CppHeaderParser
97+
- name: Run Unit Tests
98+
run: |
99+
make test
100+
- name: Generate AVR data
101+
run: |
102+
cd tools/generator
103+
make generate-avr
104+
- name: Generate SAM data
105+
run: |
106+
cd tools/generator
107+
make generate-sam
108+
- name: Generate NRF data
109+
run: |
110+
cd tools/generator
111+
make generate-nrf
112+
- name: Synchronize Docs
113+
run: |
114+
python3 tools/scripts/sync_docs.py
115+
git diff -- README.md
116+
git status --porcelain
117+
git diff $(git diff --name-only | sed -n 1p)
118+
(( $(git status --porcelain | wc -l) == 0 ))
119+

.travis.yml

-35
This file was deleted.

README.md

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ how to use this data.
1111
These tools and this data set is maintained and curated by
1212
[@salkinium][] only at [modm-io/modm-devices][modm-devices].
1313
It is licensed under the MPLv2 license.
14-
The CI checks daily for new data: [![](https://travis-ci.org/modm-io/modm-devices.svg?branch=develop)](https://travis-ci.org/modm-io/modm-devices)
1514

1615
Currently data for <!--devicecount-->3552<!--/devicecount--> devices is available.
1716
Please open an issue or better yet a pull request for additional support.

0 commit comments

Comments
 (0)