From d0ca616c19028ae4609744d15f5fd340430265e5 Mon Sep 17 00:00:00 2001 From: jcyrio <50239349+jcyrio@users.noreply.github.com> Date: Tue, 4 Jun 2024 14:02:43 -0700 Subject: [PATCH 1/7] typo: 'our our' to 'of our' (#4037) --- src/graphics/Screen.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/graphics/Screen.cpp b/src/graphics/Screen.cpp index 15e69b1ed..1c9484f62 100644 --- a/src/graphics/Screen.cpp +++ b/src/graphics/Screen.cpp @@ -2071,7 +2071,7 @@ void Screen::setFrames() LOG_DEBUG("Total frame count: %d\n", totalFrameCount); #endif - // We don't show the node info our our node (if we have it yet - we should) + // We don't show the node info of our node (if we have it yet - we should) size_t numMeshNodes = nodeDB->getNumMeshNodes(); if (numMeshNodes > 0) numMeshNodes--; @@ -2708,4 +2708,4 @@ int Screen::handleInputEvent(const InputEvent *event) } // namespace graphics #else graphics::Screen::Screen(ScanI2C::DeviceAddress, meshtastic_Config_DisplayConfig_OledType, OLEDDISPLAY_GEOMETRY) {} -#endif // HAS_SCREEN +#endif // HAS_SCREEN \ No newline at end of file From fbc8f6c03b563a7673250fbdd942fe03c152e252 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Wed, 5 Jun 2024 15:08:23 +0200 Subject: [PATCH 2/7] package x86_64 meshtasticd --- .github/workflows/main_matrix.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/main_matrix.yml b/.github/workflows/main_matrix.yml index a768e5fd9..d2338c959 100644 --- a/.github/workflows/main_matrix.yml +++ b/.github/workflows/main_matrix.yml @@ -142,6 +142,7 @@ jobs: path: | release/device-*.sh release/device-*.bat + release/meshtasticd_linux* - name: Docker login if: ${{ github.event_name != 'pull_request_target' && github.event_name != 'pull_request' }} @@ -217,7 +218,7 @@ jobs: id: version - name: Move files up - run: mv -b -t ./ ./release/meshtasticd_linux_aarch64 ./release/meshtasticd_linux_armv7l ./bin/config-dist.yaml + run: mv -b -t ./ ./release/meshtasticd_linux_* ./bin/config-dist.yaml - name: Repackage in single firmware zip uses: actions/upload-artifact@v4 From 2cc5598f8992074d7ebf5602719d174473afb525 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Wed, 5 Jun 2024 16:27:46 +0200 Subject: [PATCH 3/7] Try building a deb for native --- .github/workflows/package_amd64.yml | 78 +++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 .github/workflows/package_amd64.yml diff --git a/.github/workflows/package_amd64.yml b/.github/workflows/package_amd64.yml new file mode 100644 index 000000000..ae7bf3242 --- /dev/null +++ b/.github/workflows/package_amd64.yml @@ -0,0 +1,78 @@ +name: Package Native + +on: + workflow_call: + workflow_dispatch: + +permissions: + contents: write + packages: write + +jobs: + build-native: + uses: ./.github/workflows/build_native.yml + + package-native: + runs-on: ubuntu-latest + needs: build-native + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + submodules: recursive + ref: ${{github.event.pull_request.head.ref}} + repository: ${{github.event.pull_request.head.repo.full_name}} + + - name: Pull web ui + uses: dsaltares/fetch-gh-release-asset@master + with: + repo: meshtastic/web + file: build.tar + target: build.tar + token: ${{ secrets.GITHUB_TOKEN }} + + - name: Get release version string + run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT + id: version + + - name: Download artifacts + uses: actions/download-artifact@v4 + with: + name: firmware-native-${{ steps.version.outputs.version }}.zip + merge-multiple: true + + - name: Display structure of downloaded files + run: ls -R + + - name: build .debpkg + run: | + mkdir -p .debpkg/DEBIAN + mkdir -p .debpkg/usr/share/doc/meshtasticd/web + mkdir -p .debpkg/usr/sbin + mkdir -p .debpkg/etc/meshtasticd + mkdir -p .debpkg/usr/lib/systemd/system/ + tar -xf build.tar -C .debpkg/usr/share/doc/meshtasticd/web + gunzip .debpkg/usr/share/doc/meshtasticd/web/*.gz + cp release/meshtasticd_linux_x86_64 .debpkg/usr/sbin/meshtasticd + cp bin/config-dist.yaml .debpkg/etc/meshtasticd/config.yaml + chmod +x .debpkg/usr/sbin/meshtasticd + cp bin/meshtasticd.service .debpkg/usr/lib/systemd/system/meshtasticd.service + echo "/etc/meshtasticd/config.yaml" > .debpkg/DEBIAN/conffiles + chmod +x .debpkg/DEBIAN/conffiles + + - uses: jiro4989/build-deb-action@v3 + with: + package: meshtasticd + package_root: .debpkg + maintainer: Jonathan Bennett + version: ${{ steps.version.outputs.version }} # refs/tags/v*.*.* + arch: amd64 + depends: libyaml-cpp0.7, openssl, libulfius2.7 + desc: Native Linux Meshtastic binary. + + - uses: actions/upload-artifact@v4 + with: + name: meshtasticd_${{ steps.version.outputs.version }}_amd64.deb + overwrite: true + path: | + ./*.deb From d8775d94e371ecf24f41f9fe700fcc48218ec51b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Wed, 5 Jun 2024 16:29:40 +0200 Subject: [PATCH 4/7] try harder dude --- .github/workflows/main_matrix.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/main_matrix.yml b/.github/workflows/main_matrix.yml index d2338c959..ade018e1b 100644 --- a/.github/workflows/main_matrix.yml +++ b/.github/workflows/main_matrix.yml @@ -109,6 +109,9 @@ jobs: package-raspbian-armv7l: uses: ./.github/workflows/package_raspbian_armv7l.yml + package-native: + uses: ./.github/workflows/package_amd64.yml + build-native: runs-on: ubuntu-latest steps: From 14b7c5b6efd73c6da7361f323360a6d2e7679980 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Wed, 5 Jun 2024 16:34:30 +0200 Subject: [PATCH 5/7] Create build_native.yml --- .github/workflows/build_native.yml | 51 ++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) create mode 100644 .github/workflows/build_native.yml diff --git a/.github/workflows/build_native.yml b/.github/workflows/build_native.yml new file mode 100644 index 000000000..7c6cf6738 --- /dev/null +++ b/.github/workflows/build_native.yml @@ -0,0 +1,51 @@ +name: Build Native + +on: workflow_call + +permissions: + contents: write + packages: write + +jobs: + build-native: + runs-on: ubuntu-latest + steps: + - name: Install libbluetooth + shell: bash + run: | + apt-get install -y libbluetooth-dev libgpiod-dev libyaml-cpp-dev openssl libssl-dev libulfius-dev liborcania-dev + + - name: Checkout code + uses: actions/checkout@v4 + with: + submodules: recursive + ref: ${{github.event.pull_request.head.ref}} + repository: ${{github.event.pull_request.head.repo.full_name}} + + - name: Upgrade python tools + shell: bash + run: | + python -m pip install --upgrade pip + pip install -U platformio adafruit-nrfutil + pip install -U meshtastic --pre + + - name: Upgrade platformio + shell: bash + run: | + pio upgrade + + - name: Build Native + run: bin/build-native.sh + + - name: Get release version string + run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT + id: version + + - name: Store binaries as an artifact + uses: actions/upload-artifact@v4 + with: + name: firmware-native-${{ steps.version.outputs.version }}.zip + overwrite: true + path: | + release/meshtasticd_linux_x86_64 + bin/config-dist.yaml From f1906c38f1aa7b1e22f3e897453b774583d6895c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Wed, 5 Jun 2024 16:37:12 +0200 Subject: [PATCH 6/7] sudo make me a sandwich --- .github/workflows/build_native.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build_native.yml b/.github/workflows/build_native.yml index 7c6cf6738..d8d57a672 100644 --- a/.github/workflows/build_native.yml +++ b/.github/workflows/build_native.yml @@ -13,7 +13,7 @@ jobs: - name: Install libbluetooth shell: bash run: | - apt-get install -y libbluetooth-dev libgpiod-dev libyaml-cpp-dev openssl libssl-dev libulfius-dev liborcania-dev + sudo apt-get install -y libbluetooth-dev libgpiod-dev libyaml-cpp-dev openssl libssl-dev libulfius-dev liborcania-dev - name: Checkout code uses: actions/checkout@v4 From fb3c1412314cb607425cb562157c6e4ede8301b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Wed, 5 Jun 2024 17:04:22 +0200 Subject: [PATCH 7/7] update package index --- .github/workflows/build_native.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build_native.yml b/.github/workflows/build_native.yml index d8d57a672..257bc4176 100644 --- a/.github/workflows/build_native.yml +++ b/.github/workflows/build_native.yml @@ -13,6 +13,7 @@ jobs: - name: Install libbluetooth shell: bash run: | + sudo apt-get update sudo apt-get install -y libbluetooth-dev libgpiod-dev libyaml-cpp-dev openssl libssl-dev libulfius-dev liborcania-dev - name: Checkout code