[CI] Update sha retrieval (#1352)
This commit is contained in:
1 parent
818a091e14
commit
448b1445d3
1 file changed
+8
-7
@@ -7,20 +7,23 @@ jobs:
|
||||
name: Build and upload Assets to Release
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: benjlevesque/short-sha@v2.1
|
||||
id: short-sha
|
||||
with:
|
||||
length: 6
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: "3.7"
|
||||
- name: Set outputs
|
||||
id: vars
|
||||
run: echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install platformio requests shutils
|
||||
npm install
|
||||
- name: Set soft version tag from git
|
||||
run: sed -i "s/version_tag/${steps.vars.outputs.sha_short}/g" main/User_config.h
|
||||
- name: Set sha tag
|
||||
run: |
|
||||
sed -i "s/version_tag/${{ steps.short-sha.outputs.sha }}/g" main/User_config.h
|
||||
sed -i "s/version_tag/${{ steps.short-sha.outputs.sha }}/g" docs/.vuepress/config.js
|
||||
- name: Run PlatformIO
|
||||
run: platformio run
|
||||
- name: Prepare Release Assets
|
||||
@@ -31,8 +34,6 @@ jobs:
|
||||
uses: actions/setup-node@v1
|
||||
with:
|
||||
node-version: "14.x"
|
||||
- name: Set doc version tag from git
|
||||
run: sed -i "s/version_tag/${{steps.vars.outputs.sha_short}}/g" docs/.vuepress/config.js
|
||||
- name: Build documentation
|
||||
run: |
|
||||
python ./scripts/gen_wu_dev.py
|
||||
|
||||
Reference in new issue
Block a user