From b9f5a0745d74db8a0dc7b439821f9b3a19b43b7a Mon Sep 17 00:00:00 2001 From: Riku Isokoski Date: Tue, 5 Jul 2022 09:22:29 +0300 Subject: Don't build the firmware when only docs were modified (#1198) --- .github/workflows/main.yml | 6 ++++++ 1 file changed, 6 insertions(+) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 8d129726..eebd54bd 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,8 +8,14 @@ name: Build PineTime Firmware on: push: branches: [ master, develop ] + paths-ignore: + - 'doc/**' + - 'images/**' pull_request: branches: [ master, develop ] + paths-ignore: + - 'doc/**' + - 'images/**' jobs: build: -- cgit v1.2.3 From fdad3fc98568b5eff7c0f2729b868b8c12ce7c77 Mon Sep 17 00:00:00 2001 From: Finlay Davidson Date: Sun, 10 Jul 2022 16:46:24 +0200 Subject: Fix Docker workflow not pushing on manual trigger Also fix issue where workflow fails on pull requests when the user who made the pull request doesn't have the secrets set. Also allow other workflows to be triggered manually. Also don't trigger any workflows on pull requests to master, as there shouldn't be any pull requests against master. --- .github/workflows/docker.yml | 16 +++++++++------- .github/workflows/format.yml | 2 +- .github/workflows/lv_sim.yml | 4 +++- .github/workflows/main.yml | 4 +++- 4 files changed, 16 insertions(+), 10 deletions(-) (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index f81831ac..8d45fe08 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -15,11 +15,13 @@ on: jobs: build: runs-on: ubuntu-latest + env: + USERNAME: infinitime steps: - uses: actions/checkout@v3 - name: Log in to Docker Hub - if: github.event_name == 'push' + if: github.event_name != 'pull_request' uses: docker/login-action@v2 with: username: ${{ secrets.DOCKER_HUB_LOGIN_USERNAME }} @@ -30,7 +32,7 @@ jobs: uses: docker/metadata-action@v4 with: images: | - ${{ secrets.DOCKER_HUB_IMAGE_USERNAME }}/infinitime-build + ${{ secrets.DOCKER_HUB_IMAGE_USERNAME || env.USERNAME }}/infinitime-build tags: | type=sha type=raw,value=latest @@ -43,7 +45,7 @@ jobs: uses: docker/setup-buildx-action@v2 - name: Build and push - if: github.event_name == 'push' + if: github.event_name != 'pull_request' uses: docker/build-push-action@v3 with: context: ./docker/ @@ -53,11 +55,11 @@ jobs: push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} - cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_IMAGE_USERNAME }}/infinitime-build:buildcache - cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_IMAGE_USERNAME }}/infinitime-build:buildcache,mode=max + cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_IMAGE_USERNAME || env.USERNAME }}/infinitime-build:buildcache + cache-to: type=registry,ref=${{ secrets.DOCKER_HUB_IMAGE_USERNAME || env.USERNAME }}/infinitime-build:buildcache,mode=max - name: Build - if: github.event_name != 'push' + if: github.event_name == 'pull_request' uses: docker/build-push-action@v3 with: context: ./docker/ @@ -65,4 +67,4 @@ jobs: platforms: linux/amd64,linux/arm64 builder: ${{ steps.buildx.outputs.name }} push: false - cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_IMAGE_USERNAME }}/infinitime-build:buildcache + cache-from: type=registry,ref=${{ secrets.DOCKER_HUB_IMAGE_USERNAME || env.USERNAME }}/infinitime-build:buildcache diff --git a/.github/workflows/format.yml b/.github/workflows/format.yml index dc850096..714c60bf 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/format.yml @@ -2,7 +2,7 @@ name: Code formatting on: pull_request: - branches: [ master, develop ] + branches: [ develop ] paths: - '**.cpp' - '**.h' diff --git a/.github/workflows/lv_sim.yml b/.github/workflows/lv_sim.yml index 90ba4a76..951b3c8d 100644 --- a/.github/workflows/lv_sim.yml +++ b/.github/workflows/lv_sim.yml @@ -9,10 +9,12 @@ on: - 'doc/**' - 'images/**' pull_request: - branches: [ master, develop ] + branches: [ develop ] paths-ignore: - 'doc/**' - 'images/**' + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: jobs: build: diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index eebd54bd..69cdb715 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -12,10 +12,12 @@ on: - 'doc/**' - 'images/**' pull_request: - branches: [ master, develop ] + branches: [ develop ] paths-ignore: - 'doc/**' - 'images/**' + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: jobs: build: -- cgit v1.2.3 From e02b58bf1b760f1041bff30594cc6aac6132e6f2 Mon Sep 17 00:00:00 2001 From: Riku Isokoski Date: Sun, 21 Aug 2022 14:42:53 +0300 Subject: Move all images to doc. Remove old images. (#1282) --- .github/workflows/lv_sim.yml | 2 -- .github/workflows/main.yml | 2 -- README.md | 2 +- doc/logo/infinitime-logo-small.jpg | Bin 0 -> 31710 bytes doc/logo/infinitime-logo.jpg | Bin 0 -> 55627 bytes doc/openOCD.md | 4 ++-- doc/openOCD/pogopins.jpg | Bin 0 -> 1956623 bytes doc/openOCD/swd_pinout.jpg | Bin 0 -> 1427895 bytes images/0.14.0/collage1.png | Bin 621336 -> 0 bytes images/0.14.0/collage2.png | Bin 639600 -> 0 bytes images/0.7.0/montage.jpg | Bin 589552 -> 0 bytes images/1.0.0/collage.png | Bin 1500485 -> 0 bytes images/infinitime-logo-small.jpg | Bin 31710 -> 0 bytes images/infinitime-logo.jpg | Bin 55627 -> 0 bytes images/pinetime.jpg | Bin 51344 -> 0 bytes images/pinetimestub1.jpg | Bin 2059874 -> 0 bytes images/pogopins.jpg | Bin 1956623 -> 0 bytes images/swd_pinout.jpg | Bin 1427895 -> 0 bytes images/v0.3.0.png | Bin 1141603 -> 0 bytes images/v0.3.0/Gauge.jpg | Bin 2237900 -> 0 bytes images/v0.3.0/Helloworld.jpg | Bin 2334850 -> 0 bytes images/v0.3.0/Meter.jpg | Bin 2207746 -> 0 bytes images/v0.3.0/Version.jpg | Bin 2852866 -> 0 bytes images/v0.3.0/Watchface.jpg | Bin 1899555 -> 0 bytes images/v0.3.0/Watchface2.jpg | Bin 2411819 -> 0 bytes images/v0.3.0/menu.jpg | Bin 2362011 -> 0 bytes 26 files changed, 3 insertions(+), 7 deletions(-) create mode 100644 doc/logo/infinitime-logo-small.jpg create mode 100644 doc/logo/infinitime-logo.jpg create mode 100644 doc/openOCD/pogopins.jpg create mode 100644 doc/openOCD/swd_pinout.jpg delete mode 100644 images/0.14.0/collage1.png delete mode 100644 images/0.14.0/collage2.png delete mode 100644 images/0.7.0/montage.jpg delete mode 100644 images/1.0.0/collage.png delete mode 100644 images/infinitime-logo-small.jpg delete mode 100644 images/infinitime-logo.jpg delete mode 100644 images/pinetime.jpg delete mode 100644 images/pinetimestub1.jpg delete mode 100644 images/pogopins.jpg delete mode 100644 images/swd_pinout.jpg delete mode 100644 images/v0.3.0.png delete mode 100644 images/v0.3.0/Gauge.jpg delete mode 100644 images/v0.3.0/Helloworld.jpg delete mode 100644 images/v0.3.0/Meter.jpg delete mode 100644 images/v0.3.0/Version.jpg delete mode 100644 images/v0.3.0/Watchface.jpg delete mode 100644 images/v0.3.0/Watchface2.jpg delete mode 100644 images/v0.3.0/menu.jpg (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/lv_sim.yml b/.github/workflows/lv_sim.yml index 951b3c8d..503f5780 100644 --- a/.github/workflows/lv_sim.yml +++ b/.github/workflows/lv_sim.yml @@ -7,12 +7,10 @@ on: branches: [ master, develop ] paths-ignore: - 'doc/**' - - 'images/**' pull_request: branches: [ develop ] paths-ignore: - 'doc/**' - - 'images/**' # Allows you to run this workflow manually from the Actions tab workflow_dispatch: diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 69cdb715..45aac7ca 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -10,12 +10,10 @@ on: branches: [ master, develop ] paths-ignore: - 'doc/**' - - 'images/**' pull_request: branches: [ develop ] paths-ignore: - 'doc/**' - - 'images/**' # Allows you to run this workflow manually from the Actions tab workflow_dispatch: diff --git a/README.md b/README.md index 7c52cb44..e886bb09 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Build PineTime Firmware](https://github.com/InfiniTimeOrg/InfiniTime/workflows/Build%20PineTime%20Firmware/badge.svg?branch=master)](https://github.com/InfiniTimeOrg/InfiniTime/actions) -![InfiniTime logo](images/infinitime-logo-small.jpg "InfiniTime Logo") +![InfiniTime logo](doc/logo/infinitime-logo-small.jpg "InfiniTime Logo") Fast open-source firmware for the [PineTime smartwatch](https://www.pine64.org/pinetime/) with many features, written in modern C++. diff --git a/doc/logo/infinitime-logo-small.jpg b/doc/logo/infinitime-logo-small.jpg new file mode 100644 index 00000000..9949f5b0 Binary files /dev/null and b/doc/logo/infinitime-logo-small.jpg differ diff --git a/doc/logo/infinitime-logo.jpg b/doc/logo/infinitime-logo.jpg new file mode 100644 index 00000000..86a16f0b Binary files /dev/null and b/doc/logo/infinitime-logo.jpg differ diff --git a/doc/openOCD.md b/doc/openOCD.md index df24b30b..ef0f6605 100644 --- a/doc/openOCD.md +++ b/doc/openOCD.md @@ -99,7 +99,7 @@ openocd -f ./openocd-stlink.ocd -f ./flash_graphics.ocd ## Connect the STLinkV2 to the PineTime Here is an example using the pogo pins: -![SWD pinout](../images/swd_pinout.jpg) -![Pogo pins](../images/pogopins.jpg) +![SWD pinout](openOCD/swd_pinout.jpg) +![Pogo pins](openOCD/pogopins.jpg) You can find more information about the SWD wiring [on the wiki](https://wiki.pine64.org/index.php?title=PineTime_devkit_wiring). diff --git a/doc/openOCD/pogopins.jpg b/doc/openOCD/pogopins.jpg new file mode 100644 index 00000000..28a1c7fc Binary files /dev/null and b/doc/openOCD/pogopins.jpg differ diff --git a/doc/openOCD/swd_pinout.jpg b/doc/openOCD/swd_pinout.jpg new file mode 100644 index 00000000..1545916d Binary files /dev/null and b/doc/openOCD/swd_pinout.jpg differ diff --git a/images/0.14.0/collage1.png b/images/0.14.0/collage1.png deleted file mode 100644 index fd5f27ba..00000000 Binary files a/images/0.14.0/collage1.png and /dev/null differ diff --git a/images/0.14.0/collage2.png b/images/0.14.0/collage2.png deleted file mode 100644 index 293147dd..00000000 Binary files a/images/0.14.0/collage2.png and /dev/null differ diff --git a/images/0.7.0/montage.jpg b/images/0.7.0/montage.jpg deleted file mode 100644 index 81716cc9..00000000 Binary files a/images/0.7.0/montage.jpg and /dev/null differ diff --git a/images/1.0.0/collage.png b/images/1.0.0/collage.png deleted file mode 100644 index b9ffaa88..00000000 Binary files a/images/1.0.0/collage.png and /dev/null differ diff --git a/images/infinitime-logo-small.jpg b/images/infinitime-logo-small.jpg deleted file mode 100644 index 9949f5b0..00000000 Binary files a/images/infinitime-logo-small.jpg and /dev/null differ diff --git a/images/infinitime-logo.jpg b/images/infinitime-logo.jpg deleted file mode 100644 index 86a16f0b..00000000 Binary files a/images/infinitime-logo.jpg and /dev/null differ diff --git a/images/pinetime.jpg b/images/pinetime.jpg deleted file mode 100644 index 7f729fa5..00000000 Binary files a/images/pinetime.jpg and /dev/null differ diff --git a/images/pinetimestub1.jpg b/images/pinetimestub1.jpg deleted file mode 100644 index 3ebc34e5..00000000 Binary files a/images/pinetimestub1.jpg and /dev/null differ diff --git a/images/pogopins.jpg b/images/pogopins.jpg deleted file mode 100644 index 28a1c7fc..00000000 Binary files a/images/pogopins.jpg and /dev/null differ diff --git a/images/swd_pinout.jpg b/images/swd_pinout.jpg deleted file mode 100644 index 1545916d..00000000 Binary files a/images/swd_pinout.jpg and /dev/null differ diff --git a/images/v0.3.0.png b/images/v0.3.0.png deleted file mode 100644 index 4a2bcdd2..00000000 Binary files a/images/v0.3.0.png and /dev/null differ diff --git a/images/v0.3.0/Gauge.jpg b/images/v0.3.0/Gauge.jpg deleted file mode 100644 index aa12a01c..00000000 Binary files a/images/v0.3.0/Gauge.jpg and /dev/null differ diff --git a/images/v0.3.0/Helloworld.jpg b/images/v0.3.0/Helloworld.jpg deleted file mode 100644 index b3b09009..00000000 Binary files a/images/v0.3.0/Helloworld.jpg and /dev/null differ diff --git a/images/v0.3.0/Meter.jpg b/images/v0.3.0/Meter.jpg deleted file mode 100644 index a2c28e14..00000000 Binary files a/images/v0.3.0/Meter.jpg and /dev/null differ diff --git a/images/v0.3.0/Version.jpg b/images/v0.3.0/Version.jpg deleted file mode 100644 index d126d741..00000000 Binary files a/images/v0.3.0/Version.jpg and /dev/null differ diff --git a/images/v0.3.0/Watchface.jpg b/images/v0.3.0/Watchface.jpg deleted file mode 100644 index 1cfaa976..00000000 Binary files a/images/v0.3.0/Watchface.jpg and /dev/null differ diff --git a/images/v0.3.0/Watchface2.jpg b/images/v0.3.0/Watchface2.jpg deleted file mode 100644 index 63783051..00000000 Binary files a/images/v0.3.0/Watchface2.jpg and /dev/null differ diff --git a/images/v0.3.0/menu.jpg b/images/v0.3.0/menu.jpg deleted file mode 100644 index bf94a2e5..00000000 Binary files a/images/v0.3.0/menu.jpg and /dev/null differ -- cgit v1.2.3 From f53e75063b6ef618d65a1f287df52ba01c3351f5 Mon Sep 17 00:00:00 2001 From: Riku Isokoski Date: Thu, 25 Aug 2022 08:32:46 +0300 Subject: Merge CI to deduplicate events (#1279) --- .github/workflows/lv_sim.yml | 72 -------------------------------------------- .github/workflows/main.yml | 51 +++++++++++++++++++++++++------ 2 files changed, 42 insertions(+), 81 deletions(-) delete mode 100644 .github/workflows/lv_sim.yml (limited to '.github/workflows/main.yml') diff --git a/.github/workflows/lv_sim.yml b/.github/workflows/lv_sim.yml deleted file mode 100644 index 503f5780..00000000 --- a/.github/workflows/lv_sim.yml +++ /dev/null @@ -1,72 +0,0 @@ -# GitHub Actions Workflow to build Simulator for PineTime Smart Watch LVGL Interface - -name: Build PineTime LVGL Simulator - -on: - push: - branches: [ master, develop ] - paths-ignore: - - 'doc/**' - pull_request: - branches: [ develop ] - paths-ignore: - - 'doc/**' - # Allows you to run this workflow manually from the Actions tab - workflow_dispatch: - -jobs: - build: - runs-on: ubuntu-latest - - steps: - - ######################################################################################### - # Download and Install Dependencies - - - name: Install cmake - uses: lukka/get-cmake@v3.18.3 - - - name: Install SDL2 development package - run: | - sudo apt-get update - sudo apt-get -y install libsdl2-dev - - - name: Install lv_font_conv - run: - npm i -g lv_font_conv@1.5.2 - - ######################################################################################### - # Checkout - - - name: Checkout source files - uses: actions/checkout@v2 - with: - submodules: recursive - - ######################################################################################### - # get InfiniSim repo - - - name: Get InfiniSim repo - run: | - git clone https://github.com/InfiniTimeOrg/InfiniSim.git --depth 1 --branch main - git -C InfiniSim submodule update --init lv_drivers libpng - - ######################################################################################### - # CMake - - - name: CMake - run: | - cmake -G Ninja -S InfiniSim -B build_lv_sim -DInfiniTime_DIR="${PWD}" - - ######################################################################################### - # Build and Upload simulator - - - name: Build simulator executable - run: | - cmake --build build_lv_sim - - - name: Upload simulator executable - uses: actions/upload-artifact@v3 - with: - name: infinisim-${{ github.head_ref }} - path: build_lv_sim/infinisim diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 45aac7ca..b8a70b6e 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -1,10 +1,6 @@ -# GitHub Actions Workflow to build FreeRTOS Firmware for PineTime Smart Watch -# See https://lupyuen.github.io/pinetime-rust-mynewt/articles/cloud -# Based on https://github.com/JF002/InfiniTime/blob/master/doc/buildAndProgram.md -# and https://github.com/JF002/InfiniTime/blob/master/bootloader/README.md - -name: Build PineTime Firmware +name: CI +# Run this workflow whenever the build may be affected on: push: branches: [ master, develop ] @@ -14,11 +10,9 @@ on: branches: [ develop ] paths-ignore: - 'doc/**' - # Allows you to run this workflow manually from the Actions tab - workflow_dispatch: jobs: - build: + build-firmware: runs-on: ubuntu-latest container: image: infinitime/infinitime-build @@ -51,3 +45,42 @@ jobs: with: name: InfiniTime MCUBoot image ${{ github.head_ref }} path: ./build/output/pinetime-mcuboot-app-image-*.bin + + build-simulator: + runs-on: ubuntu-latest + steps: + - name: Install cmake + uses: lukka/get-cmake@v3.18.3 + + - name: Install SDL2 development package + run: | + sudo apt-get update + sudo apt-get -y install libsdl2-dev + + - name: Install lv_font_conv + run: + npm i -g lv_font_conv@1.5.2 + + - name: Checkout source files + uses: actions/checkout@v2 + with: + submodules: recursive + + - name: Get InfiniSim repo + run: | + git clone https://github.com/InfiniTimeOrg/InfiniSim.git --depth 1 --branch main + git -C InfiniSim submodule update --init lv_drivers libpng + + - name: CMake + run: | + cmake -G Ninja -S InfiniSim -B build_lv_sim -DInfiniTime_DIR="${PWD}" + + - name: Build simulator executable + run: | + cmake --build build_lv_sim + + - name: Upload simulator executable + uses: actions/upload-artifact@v3 + with: + name: infinisim-${{ github.head_ref }} + path: build_lv_sim/infinisim -- cgit v1.2.3