Skip to content

Commit 9bf6d99

Browse files
committed
Merge branch 'develop'
2 parents 025a683 + 1096d9b commit 9bf6d99

3 files changed

Lines changed: 9 additions & 11 deletions

File tree

.github/workflows/doxygen-gh-pages.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: Deploy Doxygen document on GitHub Pages
2-
on: [release, workflow_dispatch]
3-
# branches:
4-
# - main
5-
# - master
2+
on:
3+
release:
4+
types: [published]
5+
workflow_dispatch:
66
permissions:
77
contents: write
88
defaults:

README.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Unit Light is a light intensity detection sensor. It integrates a photoresistor
1717
## Related Link
1818
See also examples using conventional methods here.
1919

20-
- [Unit DLight & Datasheet](https://docs.m5stack.com/en/unit/dlight)
20+
- [Unit DLight & Datasheet](https://docs.m5stack.com/en/unit/DLight%20Unit)
2121
- [Hat DLight & Datasheet](https://docs.m5stack.com/en/hat/hat_dlight)
2222
- [Unit Light & Datasheet](https://docs.m5stack.com/en/unit/LIGHT)
2323

@@ -42,7 +42,7 @@ See also [M5Unit-HUB](https://github.com/m5stack/M5Unit-HUB)
4242
## Examples
4343
See also [examples/UnitUnified](examples/UnitUnified)
4444

45-
### For ArduinoIDE settings
45+
### For Arduino IDE settings
4646
You must choose a define symbol for the unit you will use.
4747
(Uncomment the corresponding #define in the example, or specify it with compile options.)
4848

@@ -73,5 +73,4 @@ If you want to output Git commit hashes to html, do it for the git cloned folder
7373

7474
### Required
7575
- [Doxygen](https://www.doxygen.nl/)
76-
- [pcregrep](https://formulae.brew.sh/formula/pcre2)
7776
- [Git](https://git-scm.com/) (Output commit hash to html)

docs/doxy.sh

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@
44

55
## Get version from library.properties
66
## Get git rev of HEAD
7-
LIB_VERSION="$(pcregrep -o1 "^\s*version\s*=\s*(\*|\d+(\.\d+){0,3}(\.\*)?)" library.properties)"
7+
LIB_VERSION="$(grep -E '^[[:space:]]*version[[:space:]]*=' library.properties | head -n1 | cut -d'=' -f2 | tr -d '[:space:]')"
88
#echo ${DOXYGEN_PROJECT_NUMBER}
9-
DOXYGEN_PROJECT_NUMBER="${LIB_VERSION} git rev:$(git rev-parse --short HEAD)" doxygen docs/Doxyfile
10-
11-
9+
GIT_REV="$(git rev-parse --short HEAD 2>/dev/null)"
10+
DOXYGEN_PROJECT_NUMBER="${LIB_VERSION}${GIT_REV:+ git rev:${GIT_REV}}" doxygen docs/Doxyfile

0 commit comments

Comments
 (0)