From 33f70f7de3246e4cdb64f2d359b6fd541235de2a Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 14:22:58 +0200 Subject: [PATCH 1/9] add demo action --- .gitea/workflows/demo.yaml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .gitea/workflows/demo.yaml diff --git a/.gitea/workflows/demo.yaml b/.gitea/workflows/demo.yaml new file mode 100644 index 0000000..c537cc6 --- /dev/null +++ b/.gitea/workflows/demo.yaml @@ -0,0 +1,19 @@ +name: Gitea Actions Demo +run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀 +on: [push] + +jobs: + Explore-Gitea-Actions: + runs-on: ubuntu-latest + steps: + - run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event." + - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!" + - run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}." + - name: Check out repository code + uses: actions/checkout@v4 + - run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner." + - run: echo "🖥️ The workflow is now ready to test your code on the runner." + - name: List files in the repository + run: | + ls ${{ gitea.workspace }} + - run: echo "🍏 This job's status is ${{ job.status }}." From 3ea11b5984ab2597dacdd5b1a33e052dab41e2d7 Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 14:41:27 +0200 Subject: [PATCH 2/9] ci: add build + unit tests workflow, lower cmake minimum to 3.22 --- .gitea/workflows/ci.yaml | 24 ++++++++++++++++++++++++ .gitea/workflows/demo.yaml | 19 ------------------- CMakeLists.txt | 2 +- 3 files changed, 25 insertions(+), 20 deletions(-) create mode 100644 .gitea/workflows/ci.yaml delete mode 100644 .gitea/workflows/demo.yaml diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml new file mode 100644 index 0000000..a871ed4 --- /dev/null +++ b/.gitea/workflows/ci.yaml @@ -0,0 +1,24 @@ +name: CI + +on: [push, pull_request] + +jobs: + build-and-test: + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y gcc cmake libzstd-dev + + - name: Configure + run: cmake -B build -S . + + - name: Build + run: cmake --build build -j$(nproc) + + - name: Unit Tests + run: ./build/tests diff --git a/.gitea/workflows/demo.yaml b/.gitea/workflows/demo.yaml deleted file mode 100644 index c537cc6..0000000 --- a/.gitea/workflows/demo.yaml +++ /dev/null @@ -1,19 +0,0 @@ -name: Gitea Actions Demo -run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀 -on: [push] - -jobs: - Explore-Gitea-Actions: - runs-on: ubuntu-latest - steps: - - run: echo "🎉 The job was automatically triggered by a ${{ gitea.event_name }} event." - - run: echo "🐧 This job is now running on a ${{ runner.os }} server hosted by Gitea!" - - run: echo "🔎 The name of your branch is ${{ gitea.ref }} and your repository is ${{ gitea.repository }}." - - name: Check out repository code - uses: actions/checkout@v4 - - run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner." - - run: echo "🖥️ The workflow is now ready to test your code on the runner." - - name: List files in the repository - run: | - ls ${{ gitea.workspace }} - - run: echo "🍏 This job's status is ${{ job.status }}." diff --git a/CMakeLists.txt b/CMakeLists.txt index 6555105..2100f70 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 4.1) +cmake_minimum_required(VERSION 3.22) project(FastFileTransfer) From e7087d518b8081b78d55ae870e2d366482525cd2 Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 14:43:02 +0200 Subject: [PATCH 3/9] ci: skip apt-get update for faster installs --- .gitea/workflows/ci.yaml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index a871ed4..920fc95 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -10,9 +10,7 @@ jobs: uses: actions/checkout@v4 - name: Install dependencies - run: | - sudo apt-get update - sudo apt-get install -y gcc cmake libzstd-dev + run: sudo apt-get install -y --no-install-recommends gcc cmake libzstd-dev - name: Configure run: cmake -B build -S . From 36da0d6adbd35fd945e3f05f01d4b01ab4f6635c Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 14:45:03 +0200 Subject: [PATCH 4/9] ci: restore apt-get update for package resolution --- .gitea/workflows/ci.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index 920fc95..eecd7ce 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -10,7 +10,9 @@ jobs: uses: actions/checkout@v4 - name: Install dependencies - run: sudo apt-get install -y --no-install-recommends gcc cmake libzstd-dev + run: | + sudo apt-get update + sudo apt-get install -y --no-install-recommends gcc cmake libzstd-dev - name: Configure run: cmake -B build -S . From 9130ee4b03a1c7b9f0585618a4d5c0c6dd80bb01 Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 15:15:26 +0200 Subject: [PATCH 5/9] ci: use custom Docker image with build tools pre-installed --- .gitea/workflows/ci.yaml | 6 +----- Dockerfile | 4 ++++ 2 files changed, 5 insertions(+), 5 deletions(-) create mode 100644 Dockerfile diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index eecd7ce..bddb96a 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -5,15 +5,11 @@ on: [push, pull_request] jobs: build-and-test: runs-on: ubuntu-latest + container: gitea.tap-tap.win/taptap/fastsync-ci:latest steps: - name: Checkout uses: actions/checkout@v4 - - name: Install dependencies - run: | - sudo apt-get update - sudo apt-get install -y --no-install-recommends gcc cmake libzstd-dev - - name: Configure run: cmake -B build -S . diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..9d32c97 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,4 @@ +FROM ubuntu:24.04 +RUN apt-get update && apt-get install -y --no-install-recommends \ + gcc cmake libzstd-dev git ca-certificates && \ + rm -rf /var/lib/apt/lists/* From 5fe40a5242bc6ab5b1dcf06bee374161c64f0b4d Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 15:19:41 +0200 Subject: [PATCH 6/9] ci: add node.js to Docker image for checkout action --- Dockerfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 9d32c97..79874cb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,6 @@ FROM ubuntu:24.04 RUN apt-get update && apt-get install -y --no-install-recommends \ - gcc cmake libzstd-dev git ca-certificates && \ + gcc cmake libzstd-dev git ca-certificates curl && \ + curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \ + apt-get install -y --no-install-recommends nodejs && \ rm -rf /var/lib/apt/lists/* From cc09bedc071ea13ceef9e26b15c573d0174ab56b Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 15:20:57 +0200 Subject: [PATCH 7/9] ci: use v2 image tag to bypass runner cache --- .gitea/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index bddb96a..97388fc 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -5,7 +5,7 @@ on: [push, pull_request] jobs: build-and-test: runs-on: ubuntu-latest - container: gitea.tap-tap.win/taptap/fastsync-ci:latest + container: gitea.tap-tap.win/taptap/fastsync-ci:v2 steps: - name: Checkout uses: actions/checkout@v4 From 8c7ebbfe320716cf5297ad9e760098980c80ee29 Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 15:27:35 +0200 Subject: [PATCH 8/9] ci: add make to Docker image, use v3 tag --- .gitea/workflows/ci.yaml | 2 +- Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index 97388fc..35a2177 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -5,7 +5,7 @@ on: [push, pull_request] jobs: build-and-test: runs-on: ubuntu-latest - container: gitea.tap-tap.win/taptap/fastsync-ci:v2 + container: gitea.tap-tap.win/taptap/fastsync-ci:v3 steps: - name: Checkout uses: actions/checkout@v4 diff --git a/Dockerfile b/Dockerfile index 79874cb..77a985c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM ubuntu:24.04 RUN apt-get update && apt-get install -y --no-install-recommends \ - gcc cmake libzstd-dev git ca-certificates curl && \ + gcc cmake make libzstd-dev git ca-certificates curl && \ curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \ apt-get install -y --no-install-recommends nodejs && \ rm -rf /var/lib/apt/lists/* From ed7f8ee56e3792b1776206a7bbc88358b3b14d0c Mon Sep 17 00:00:00 2001 From: TapTap Date: Sat, 18 Jul 2026 15:31:41 +0200 Subject: [PATCH 9/9] ci: add g++ and libc6-dev, use v4 image (verified locally) --- .gitea/workflows/ci.yaml | 2 +- Dockerfile | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/ci.yaml b/.gitea/workflows/ci.yaml index 35a2177..29e2a22 100644 --- a/.gitea/workflows/ci.yaml +++ b/.gitea/workflows/ci.yaml @@ -5,7 +5,7 @@ on: [push, pull_request] jobs: build-and-test: runs-on: ubuntu-latest - container: gitea.tap-tap.win/taptap/fastsync-ci:v3 + container: gitea.tap-tap.win/taptap/fastsync-ci:v4 steps: - name: Checkout uses: actions/checkout@v4 diff --git a/Dockerfile b/Dockerfile index 77a985c..fe7faa4 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,6 @@ FROM ubuntu:24.04 RUN apt-get update && apt-get install -y --no-install-recommends \ - gcc cmake make libzstd-dev git ca-certificates curl && \ + gcc g++ make libc6-dev cmake libzstd-dev git ca-certificates curl && \ curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && \ apt-get install -y --no-install-recommends nodejs && \ rm -rf /var/lib/apt/lists/*