Skip to content

Commit 35fd003

Browse files
committed
Add Github Actions and templates
1 parent ca93798 commit 35fd003

8 files changed

+503
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
name: Feature request
2+
description: Suggest an idea for this project
3+
labels: ["Type: Feature request"]
4+
assignees: self
5+
6+
body:
7+
- type: markdown
8+
attributes:
9+
value: |
10+
Thanks for taking the time to request a feature or suggest a new idea!
11+
* Before reporting a feature please check and search in [List of existing issues](https://github.com/Erriez/ErriezMHZ19B/issues?q=is%3Aissue)
12+
* Please check [Online Documentation](https://github.com/Erriez/ErriezMHZ19B/blob/master/README.md)
13+
14+
- type: input
15+
id: feature
16+
attributes:
17+
label: Feature request
18+
description: Please briefly explain your feature request.
19+
placeholder: eg. Missing / add board support, specific peripheral...
20+
validations:
21+
required: true
22+
23+
- type: textarea
24+
id: hardware
25+
attributes:
26+
label: Hardware setup
27+
description: What kind should this feature work on?
28+
placeholder: ex. Arduino UNO, DUE, ESP8266, ESP32...
29+
validations:
30+
required: true
31+
32+
- type: textarea
33+
id: related
34+
attributes:
35+
label: Is your feature request related to a problem?
36+
description: Please provide a clear and concise description of what the problem is. Add relevant issue link.
37+
placeholder: ex. Related issue ID...
38+
validations:
39+
required: true
40+
41+
- type: textarea
42+
id: solution
43+
attributes:
44+
label: Describe the solution you'd like
45+
description: Please provide a clear and concise description of what you want to happen.
46+
placeholder: ex. When using this function...
47+
validations:
48+
required: true
49+
50+
- type: textarea
51+
id: context
52+
attributes:
53+
label: Additional context
54+
description: Please add any other context or screenshots about the feature request here.
55+
placeholder: ex. This would work only when ...
56+
57+
- type: checkboxes
58+
id: confirmation
59+
attributes:
60+
label: Checks
61+
description: You agree to check all the resources above before opening a new feature request.
62+
options:
63+
- label: I confirm I have checked existing issues, online documentation and latest version when possible.
64+
required: true
65+
options:
66+
- label: I understand that this library is maintained by volunteers in spare time. Response time may vary.
67+
required: true
68+
69+
- type: checkboxes
70+
id: restrictions
71+
attributes:
72+
label: Export restrictions.
73+
description: The owner of this repository Erriez included an explict export restriction to Russia.
74+
options:
75+
- label: I accept [End User Agreement](https://github.com/Erriez/ErriezMHZ19B/blob/master/END_USER_AGREEMENT.md).
76+
required: true
77+
78+
- type: markdown
79+
attributes:
80+
value: Thanks for your contribution!
+114
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
name: Issue report
2+
description: Report issues
3+
labels: ["Awaiting triage"]
4+
assignees: self
5+
6+
body:
7+
- type: markdown
8+
attributes:
9+
value: |
10+
Thanks for taking the time to report an issue!
11+
* Before reporting a new issue please check and search in [List of existing issues](https://github.com/Erriez/ErriezMHZ19B/issues?q=is%3Aissue)
12+
* Please check [Online Documentation](https://github.com/Erriez/ErriezMHZ19B/blob/master/README.md)
13+
14+
- type: input
15+
id: board
16+
attributes:
17+
label: Board
18+
description: On which Board does this issue occur?
19+
placeholder: ex. Arduino Uno, Mini, Leonardo, Mega2560, DUE, ESP8266 NodeMCU, ESP32-S2...
20+
validations:
21+
required: true
22+
23+
- type: textarea
24+
id: hardware
25+
attributes:
26+
label: Hardware setup
27+
description: What kind of hardware is attached to the chip?
28+
placeholder: ex. Exact sensor/device types, etc. If your hardware is custom or unusual, please attach a photo.
29+
validations:
30+
required: true
31+
32+
- type: dropdown
33+
id: version
34+
attributes:
35+
label: Version
36+
description: What version of this library is used? Please consider to update to the latest version when possible.
37+
options:
38+
- latest master (checkout manually)
39+
- v1.0.0
40+
- other
41+
validations:
42+
required: true
43+
44+
- type: input
45+
id: IDE
46+
attributes:
47+
label: IDE Name
48+
description: What IDE are you using?
49+
placeholder: ex. Arduino IDE, PlatformIO, etc...
50+
validations:
51+
required: true
52+
53+
- type: textarea
54+
id: description
55+
attributes:
56+
label: Description
57+
description: Please describe your problem here and expected behaviour.
58+
placeholder: ex. Build error, weird or wrong behaviour, etc..
59+
validations:
60+
required: true
61+
62+
- type: textarea
63+
id: testcase
64+
attributes:
65+
label: Testcase
66+
description: Please describe exact steps to reproduce your problem.
67+
placeholder: ex. 1. Build example XYZ, 2. Run on the board, 3. Send message..., etc
68+
validations:
69+
required: true
70+
71+
- type: textarea
72+
id: sketch
73+
attributes:
74+
label: Sketch
75+
description: Please provide full minimal sketch/code which can be run to reproduce your issue.
76+
placeholder: ex. Related part of the code to replicate the issue
77+
render: cpp
78+
validations:
79+
required: true
80+
81+
- type: textarea
82+
id: logs
83+
attributes:
84+
label: Logs
85+
description: Please provide a logs or error message.
86+
placeholder: When possible, enable Core debug level - Debug on tools menu of Arduino IDE, then put the serial output here.
87+
render: plain
88+
validations:
89+
required: true
90+
91+
- type: checkboxes
92+
id: confirmation
93+
attributes:
94+
label: Checks
95+
description: You agree to check all the resources above before opening a new issue.
96+
options:
97+
- label: I confirm I have checked existing issues, online documentation and latest version when possible.
98+
required: true
99+
options:
100+
- label: I understand that this library is maintained by volunteers in spare time. Response time may vary.
101+
required: true
102+
103+
- type: checkboxes
104+
id: restrictions
105+
attributes:
106+
label: Export restrictions.
107+
description: The owner of this repository Erriez included an explict export restriction to Russia.
108+
options:
109+
- label: I accept [End User Agreement](https://github.com/Erriez/ErriezMHZ19B/blob/master/END_USER_AGREEMENT.md).
110+
required: true
111+
112+
- type: markdown
113+
attributes:
114+
value: Thanks for your contribution!

.github/pull_request_template.md

+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
## Checklist
2+
3+
Thanks for taking the time to create a pull request!
4+
5+
1. [ ] The title of the PR contains a clear description (eg: "Update PDF URL in README.md")
6+
2. [ ] I could not find [related issues](https://github.com/Erriez/ErriezMHZ19B/issues?q=is%3Aissue).
7+
3. [ ] I have tested this pull request and updated documentation.
8+
4. [ ] I understand that this library is maintained by volunteers in spare time. Response time may vary.
9+
4. [ ] I accept the export restriction to Russia in [End User Agreement](https://github.com/Erriez/ErriezMHZ19B/blob/master/END_USER_AGREEMENT.md).
10+
11+
**This entire section above can be deleted if all items are checked.**
12+
13+
-----------
14+
15+
## Description and Impact
16+
Describe your proposed Pull Request and it's impact:
17+
This pull request fixes an issue with... and affects boards...
18+
19+
## Link to other issues
20+
Provide relevant links to related issues, PRs etc:
21+
Issue #123
22+
23+
## Tested version
24+
Which version was used to test this pull request?
25+
- Branch: master
26+
- Hash: 123456
27+
- Tag: v1.0.0
28+
29+
Thanks for your contribution!

.github/workflows/actions.yml

+110
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,110 @@
1+
name: Github Actions CI
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
- staging/erriez/*
8+
pull_request:
9+
branches:
10+
- master
11+
schedule:
12+
# */2: even, */4: every 4
13+
# +--------------> minute (0 - 59)
14+
# | +------------> hour (0 - 23)
15+
# | | +----------> day of the month (1 - 31)
16+
# | | | +--------> month (1 - 12)
17+
# | | | | +------> day of the week (0 - 6)
18+
# | | | | |
19+
- cron: "0 0 1 */4 *"
20+
# Run this workflow manually from the Actions tab
21+
workflow_dispatch:
22+
23+
env:
24+
# To use repository name: ${{ github.event.repository.name }}
25+
PDF_NAME: ${{ github.event.repository.name }}
26+
27+
jobs:
28+
build:
29+
runs-on: ubuntu-latest
30+
strategy:
31+
matrix:
32+
examples: [
33+
examples/ErriezMHZ19B7SegmentDisplay/ErriezMHZ19B7SegmentDisplay.ino,
34+
examples/ErriezMHZ19BGettingStarted/ErriezMHZ19BGettingStarted.ino,
35+
examples/ErriezMHZ19BSerialPlottter/ErriezMHZ19BSerialPlottter.ino,
36+
examples/ErriezMHZ19BESP8266MQTT/ErriezMHZ19BESP8266MQTT.ino
37+
]
38+
39+
steps:
40+
- uses: actions/checkout@v3
41+
42+
- uses: actions/cache@v3
43+
with:
44+
path: |
45+
~/.cache/pip
46+
~/.platformio/.cache
47+
key: ${{ runner.os }}-pio
48+
49+
- uses: actions/setup-python@v4
50+
with:
51+
python-version: '3.9'
52+
53+
- name: Install PlatformIO Core
54+
run: pip install --upgrade platformio
55+
56+
- name: Install library dependencies
57+
run: |
58+
pio pkg install --global --library https://github.com/Erriez/ErriezTM1637
59+
pio pkg install --global --library https://github.com/Erriez/ErriezRobotDyn4DigitDisplay
60+
pio pkg install --global --library https://github.com/knolleary/pubsubclient
61+
62+
echo "Install ESPSoftwareSerial into framework-arduinoespressif32 to prevent conflicts with generic name SoftwareSerial"
63+
mkdir -p ~/.platformio/packages/framework-arduinoespressif32/libraries
64+
platformio lib --storage-dir ~/.platformio/packages/framework-arduinoespressif32/libraries install "EspSoftwareSerial@6.16.1"
65+
# Cannot upgrade to pio pkg install command: https://github.com/platformio/platformio-core/issues/4410
66+
#pio pkg install --storage-dir ~/.platformio/packages/framework-arduinoespressif32/libraries --library "EspSoftwareSerial@6.16.1"
67+
68+
- name: Build PlatformIO examples Arduino
69+
run: |
70+
# Use option -O "lib_ldf_mode=chain+" to parse defines
71+
pio ci -O "lib_ldf_mode=chain+" --lib="." --board=uno --board micro --board pro16MHzatmega328 --board pro8MHzatmega328 --board megaatmega2560 --board leonardo --board due --board nodemcuv2 --board lolin_d32
72+
env:
73+
PLATFORMIO_CI_SRC: ${{ matrix.examples }}
74+
75+
doxygen:
76+
runs-on: ubuntu-latest
77+
steps:
78+
- name: Checkout repository
79+
uses: actions/checkout@v3
80+
with:
81+
submodules: "true"
82+
83+
- name: Install Doxygen
84+
run: sudo apt-get install doxygen graphviz -y
85+
shell: bash
86+
87+
- name: Generate Doxygen HTML
88+
run: doxygen Doxyfile
89+
shell: bash
90+
91+
- name: Create .nojekyll (ensures pages with underscores work on gh pages)
92+
run: touch docs/html/.nojekyll
93+
shell: bash
94+
95+
- name: Generate Doxygen PDF
96+
if: ${{ github.ref == 'refs/heads/master' }}
97+
run: |
98+
sudo apt-get install texlive-latex-recommended texlive-pictures texlive-latex-extra -y
99+
make -C docs/latex
100+
cp docs/latex/refman.pdf docs/html/$PDF_NAME.pdf
101+
shell: bash
102+
103+
- name: Deploy to GitHub branch gh-pages
104+
if: ${{ github.ref == 'refs/heads/master' }}
105+
uses: JamesIves/github-pages-deploy-action@v4
106+
with:
107+
github_token: ${{ secrets.GITHUB_TOKEN }}
108+
branch: gh-pages
109+
folder: docs/html
110+

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,5 @@
3232
*.app
3333

3434
.idea/
35+
.venv/
3536
docs/

0 commit comments

Comments
 (0)