mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-02-18 19:03:16 +00:00
Fixed & improved build scripts (#288)
* Fixed&improved build scripts * Fixes and updates * Fix for esp-idf-ci-action * Build fixes
This commit is contained in:
parent
1593eb80ce
commit
a091923353
2
.github/actions/build-firmware/action.yml
vendored
2
.github/actions/build-firmware/action.yml
vendored
@ -18,7 +18,7 @@ runs:
|
||||
shell: bash
|
||||
run: cp sdkconfig.board.${{ inputs.board_id }} sdkconfig
|
||||
- name: 'Build'
|
||||
uses: espressif/esp-idf-ci-action@main
|
||||
uses: espressif/esp-idf-ci-action@v1
|
||||
with:
|
||||
esp_idf_version: v5.4
|
||||
target: ${{ inputs.arch }}
|
||||
|
||||
6
.github/actions/build-sdk/action.yml
vendored
6
.github/actions/build-sdk/action.yml
vendored
@ -18,13 +18,17 @@ runs:
|
||||
shell: bash
|
||||
run: cp sdkconfig.board.${{ inputs.board_id }} sdkconfig
|
||||
- name: 'Build'
|
||||
uses: espressif/esp-idf-ci-action@main
|
||||
uses: espressif/esp-idf-ci-action@v1
|
||||
with:
|
||||
# NOTE: Update with ESP-IDF!
|
||||
esp_idf_version: v5.4
|
||||
target: ${{ inputs.arch }}
|
||||
path: './'
|
||||
- name: 'Release'
|
||||
shell: bash
|
||||
env:
|
||||
# NOTE: Update with ESP-IDF!
|
||||
ESP_IDF_VERSION: '5.4'
|
||||
run: Buildscripts/release-sdk.sh release/TactilitySDK
|
||||
- name: 'Upload Artifact'
|
||||
uses: actions/upload-artifact@v4
|
||||
|
||||
@ -19,7 +19,7 @@ function(INIT_TACTILITY_GLOBALS SDKCONFIG_FILE)
|
||||
set(id_length 0)
|
||||
math(EXPR id_length "${sdkconfig_board_id_length} - 21")
|
||||
string(SUBSTRING ${sdkconfig_board_id} 20 ${id_length} board_id)
|
||||
message("Building board: ${Cyan}${board_id}${ColorReset}")
|
||||
message("Board name: ${Cyan}${board_id}${ColorReset}")
|
||||
|
||||
if (board_id STREQUAL "cyd-2432s024c")
|
||||
set(TACTILITY_BOARD_PROJECT CYD-2432S024C)
|
||||
@ -62,7 +62,7 @@ function(INIT_TACTILITY_GLOBALS SDKCONFIG_FILE)
|
||||
if (TACTILITY_BOARD_PROJECT STREQUAL "")
|
||||
message(FATAL_ERROR "No subproject mapped to \"${TACTILITY_BOARD_ID}\" in root Buildscripts/board.cmake")
|
||||
else ()
|
||||
message("Board project: ${Cyan}Boards/${TACTILITY_BOARD_PROJECT}${ColorReset}\n")
|
||||
message("Board path: ${Cyan}Boards/${TACTILITY_BOARD_PROJECT}${ColorReset}\n")
|
||||
set_property(GLOBAL PROPERTY TACTILITY_BOARD_PROJECT ${TACTILITY_BOARD_PROJECT})
|
||||
set_property(GLOBAL PROPERTY TACTILITY_BOARD_ID ${board_id})
|
||||
endif ()
|
||||
|
||||
@ -27,12 +27,13 @@ fi
|
||||
|
||||
echoNewPhase "Cleaning build folder"
|
||||
|
||||
rm -rf build
|
||||
#rm -rf build
|
||||
|
||||
echoNewPhase "Building $sdkconfig_file"
|
||||
|
||||
cp $sdkconfig_file sdkconfig
|
||||
if not idf.py build; then
|
||||
idf.py build
|
||||
if [[ $? != 0 ]]; then
|
||||
fatalError "Failed to build esp32s3 SDK"
|
||||
fi
|
||||
|
||||
|
||||
@ -21,7 +21,7 @@ file(READ version.txt TACTILITY_VERSION)
|
||||
add_compile_definitions(TT_VERSION="${TACTILITY_VERSION}")
|
||||
|
||||
if (DEFINED ENV{ESP_IDF_VERSION})
|
||||
message("Building with ESP-IDF ${Cyan}v$ENV{ESP_IDF_VERSION}${ColorReset}")
|
||||
message("Using ESP-IDF ${Cyan}v$ENV{ESP_IDF_VERSION}${ColorReset}")
|
||||
include($ENV{IDF_PATH}/tools/cmake/project.cmake)
|
||||
|
||||
include("Buildscripts/board.cmake")
|
||||
|
||||
22
Documentation/releasing.md
Normal file
22
Documentation/releasing.md
Normal file
@ -0,0 +1,22 @@
|
||||
# Releasing Tactility
|
||||
|
||||
1. Test the latest version on several devices
|
||||
2. Build the SDK locally and test it with `ExternalApps/HelloWorld`
|
||||
3. Test the latest SDK build from GitHub with the CDN:
|
||||
1. Download it from the [main branch](https://github.com/ByteWelder/Tactility/actions/workflows/build-sdk.yml)
|
||||
2. Upload it to the [CDN](https://dash.cloudflare.com)
|
||||
3. Update `sdk.json` from [TactilityTool](https://github.com/ByteWelder/TactilityTool) and upload it to [CDN](https://dash.cloudflare.com)
|
||||
4. Test it with `ExternalApps/HelloWorld` (clear all its cache and update the SDK version)
|
||||
4. Download the latest firmwares [main branch](https://github.com/ByteWelder/Tactility/actions/workflows/build-firmware.yml)
|
||||
5. Prepare a new version of [TactilityWebInstaller](https://github.com/ByteWelder/TactilityWebInstaller) locally
|
||||
6. Test the firmwares on all devices with the local web installer
|
||||
7. If all went well: release the web installer
|
||||
8. Test web installer in production (use popular devices)
|
||||
9. Make a new version of the docs available at [TactilityDocs](https://github.com/ByteWelder/TactilityDocs)
|
||||
10. Make a new [GitHub release](https://github.com/ByteWelder/Tactility/releases/new)
|
||||
|
||||
### Post-release
|
||||
|
||||
1. Mention on Discord
|
||||
2. Consider notifying vendors/stakeholders
|
||||
3. Remove dev versions in `sdk.json`from [TactilityTool](https://github.com/ByteWelder/TactilityTool) and upload it to [CDN](https://dash.cloudflare.com)
|
||||
@ -217,7 +217,7 @@ def sdk_download(version, platform):
|
||||
print(f"Downloading SDK version {version} for {platform}")
|
||||
if download_file(sdk_url, filepath):
|
||||
with zipfile.ZipFile(filepath, "r") as zip_ref:
|
||||
zip_ref.extractall(sdk_root_dir)
|
||||
zip_ref.extractall(os.path.join(sdk_root_dir, "TactilitySDK"))
|
||||
return True
|
||||
else:
|
||||
return False
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user