Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,18 +18,17 @@ A clear and concise description of what you expected to happen.
**Reproduction steps**

Steps to reproduce the bug.
<!-- Usually this means a small and self-contained piece of code that uses Catch and specifying compiler flags if relevant. -->

<!-- Usually this means a small and self-contained piece of code that uses Google Test and specifying compiler flags if relevant. -->

**Platform information:**

<!-- Fill in any extra information that might be important for your issue. -->

- OS: **Windows NT-WSL-1**
- Compiler+version: **GCC 7.5.0**
- release version: **0.0.5**

- OS: **Windows NT-WSL-2 Ubuntu 26.04**
- Compiler+version: **GCC 15.2.0**
- release version: **0.15.0**

**Additional context**

Add any other context about the problem here.
Add any other context about the problem here.
24 changes: 10 additions & 14 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,16 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-24.04 ]
os: [ ubuntu-26.04 ]
env:
CC: gcc-13
CXX: g++-13
CC: gcc-15
CXX: g++-15
# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v5
- uses: actions/cache@v4
- uses: certseeds/common-actions/actions/checkout@v1
- uses: certseeds/common-actions/actions/cache@v1
env:
cache-name: cache-cmake-files
with:
Expand All @@ -46,15 +45,12 @@ jobs:

- name: Install ccache, check gcc version
run: |
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update && sudo apt-get install -y ccache
sudo apt-get update
sudo apt-get install -y ccache
sudo apt-get install -y libgtest-dev libgmock-dev
gcc --version
g++ --version

- name: prepare deps
run: |
bash ./third_party/install.sh

- name: Use cmake
run: cmake --version

Expand Down Expand Up @@ -89,14 +85,14 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-24.04 ]
os: [ ubuntu-26.04 ]

# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v5
uses: certseeds/common-actions/actions/checkout@v1

# ensure the path and files of project
- name: ensure the path and files of project
Expand Down
62 changes: 16 additions & 46 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,31 +16,28 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-24.04 ]
os: [ ubuntu-26.04 ]
env:
CC: gcc-13
CXX: g++-13
CC: gcc-15
CXX: g++-15
# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v5
uses: certseeds/common-actions/actions/checkout@v1

- name: hardwares - cpu
run: nproc; cat /proc/cpuinfo

- name: Install ccache, check gcc version
run: |
sudo add-apt-repository ppa:ubuntu-toolchain-r/test
sudo apt-get update && sudo apt-get install -y ccache
yes | sudo apt-get update
yes | sudo apt-get install ccache
yes | sudo apt-get install libgtest-dev libgmock-dev
gcc --version
g++ --version

- name: prepare deps
run: |
bash ./third_party/install.sh

- name: Use cmake
run: cmake --version

Expand All @@ -63,18 +60,18 @@ jobs:
build:
name: publish release
env:
CC: gcc-13
CXX: g++-13
CC: gcc-15
CXX: g++-15
if: github.repository == 'Certseeds/algorithm-template'
needs: test
# The type of runner that the job will run on
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v5
uses: certseeds/common-actions/actions/checkout@v1

- name: Branch name
id: branch_name
Expand All @@ -94,17 +91,6 @@ jobs:
- name: ensure the path and files of project
run: sudo apt-get install tree; tree; mkdir -p ./cmake_build_release

- name: prepare deps
run: |
bash ./third_party/install.sh
bash ./third_party/rename.sh

- name: move cmake-fetchcontent to folder
working-directory: ./third_party
run: |
rm ./CMakeLists.txt
mv ./CMakeLists.release.txt ./CMakeLists.txt

- name: run script
working-directory: ./script
run: python3 file_template.py
Expand All @@ -116,7 +102,7 @@ jobs:
tree

- name: release
uses: softprops/action-gh-release@v2
uses: softprops/action-gh-release@v3
if: startsWith(github.ref, 'refs/tags/')
with:
files: ./../script_no_need.zip
Expand All @@ -129,18 +115,18 @@ jobs:
release-branch:
name: publish release-branch
env:
CC: gcc-13
CXX: g++-13
CC: gcc-15
CXX: g++-15
if: github.repository == 'Certseeds/algorithm-template'
needs: [ test, build ]
# The type of runner that the job will run on
runs-on: ubuntu-24.04
runs-on: ubuntu-26.04
# Steps represent a sequence of tasks that will be executed as part of the job
steps:

# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: checkout code
uses: actions/checkout@v5
uses: certseeds/common-actions/actions/checkout@v1

- name: Branch name
id: branch_name
Expand All @@ -152,26 +138,10 @@ jobs:
env:
SOURCE_NAME: ${{ steps.branch_name.outputs.SOURCE_NAME }}


- name: prepare deps
run: |
bash ./third_party/install.sh
bash ./third_party/rename.sh

- name: git operations
run: |
git config --global user.name 'Certseeds'
git config --global user.email '51754303+Certseeds@users.noreply.github.com'
git checkout --orphan release

- name: move cmake-fetchcontent to folder
working-directory: ./third_party
run: |
echo '**/.github/*' > ./.gitignore
rm ./CMakeLists.txt
mv ./CMakeLists.release.txt ./CMakeLists.txt
git add -A
git commit -am "init: with deps"

- name: run script
working-directory: ./script
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -297,3 +297,4 @@ $RECYCLE.BIN/
# test files begin
*.test.out
*.zip
node_modules
5 changes: 3 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required(VERSION 3.16.6)

set(PROJECT_VERSION_MAJOR 0)
set(PROJECT_VERSION_MINOR 15)
set(PROJECT_VERSION_MINOR 16)
set(PROJECT_VERSION_PATCH 0) # delete endsWith strs when master merge dev

project(algorithm_template
Expand All @@ -18,8 +18,9 @@ string(TIMESTAMP time_str "%Y/%m/%d %H:%M:%S")
MESSAGE(STATUS "Compiler In \n ${time_str}")

include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/CMakeLists.txt)

find_package(GTest REQUIRED)
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/include)
add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/third_party)

enable_testing()
file(GLOB USER_LIBS_PATH ${CMAKE_CURRENT_SOURCE_DIR}/lab_*) # regex to find libs, more flexibility
Expand Down
Loading