Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade build system #75

Open
wants to merge 46 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
47b1182
[git] Deinit ostis-web-platform and googletest
NikitaZotov Jan 31, 2025
a7f8e97
[solver] Move to upgraded build system
NikitaZotov Feb 1, 2025
871271a
[cmake][conan] Update cmake files; add conan
NikitaZotov Feb 1, 2025
578f8fd
[scripts] Remove build scripts; update clang-format scripts
NikitaZotov Feb 1, 2025
e6b0aff
[git] Ignore repo folder
NikitaZotov Feb 1, 2025
2ea5500
[solver] Rename test-starters to tests
NikitaZotov Feb 1, 2025
f1f1db1
[config] Remove extensions option from config
NikitaZotov Feb 1, 2025
c31617f
[tests] Add settings for TestMate
NikitaZotov Feb 1, 2025
f3dccff
[ci] Add test and release ci
NikitaZotov Feb 1, 2025
66c11b8
[refactor] Rename scp-machine to ostis-metasystem
NikitaZotov Feb 1, 2025
4a3617b
[docs] Update readme
NikitaZotov Feb 1, 2025
998168e
[docs] Rename LICENSE to COPYING.MIT
NikitaZotov Feb 1, 2025
b2ead7c
[docs] Add CONTRIBUTING
NikitaZotov Feb 1, 2025
e3de9e5
[ci] Run old testing ci
NikitaZotov Feb 1, 2025
2deb77b
[scripts] Remove all test and install scripts
NikitaZotov Feb 1, 2025
f08a676
[config] Remove platform repo.path from repo.path
NikitaZotov Feb 1, 2025
e5161e2
[git] Add react-sc-web submodule
NikitaZotov Feb 1, 2025
c3795c1
[docs] Add build system docs and quick start for contributors
NikitaZotov Feb 2, 2025
c53a75e
[build][conan] Add nlohmann_json dependency
NikitaZotov Feb 2, 2025
9d1fecc
[git] Add react-sc-web submodule
NikitaZotov Feb 2, 2025
f3610e1
[docs] Update possible commit tags in CONtIBUTING.md
NikitaZotov Feb 2, 2025
d149cfd
[interface] Rename user-interface folder to interface
NikitaZotov Feb 2, 2025
773f921
[scripts] Add install problem solver script
NikitaZotov Feb 2, 2025
eeb3562
[git] Ignore install folder
NikitaZotov Feb 2, 2025
73cef1e
[docs] Add quick start for users
NikitaZotov Feb 2, 2025
56bb817
[solver][cmake] Append agent modules into extensions folder
NikitaZotov Feb 2, 2025
fd57ed7
[config] Don't ignore interface specification
NikitaZotov Feb 2, 2025
5c7cdf6
[kb] Install ostis-standard by its specification
NikitaZotov Feb 2, 2025
9be8965
[config] Install components into install directories
NikitaZotov Feb 2, 2025
2516030
[solver][py] Move Python problem solver to new API
NikitaZotov Feb 3, 2025
c950acf
[docs] Add quick start sections for Python problem solver and interfa…
NikitaZotov Feb 3, 2025
e761024
[scripts][refactor] Rename install_problem_solver.sh to install_cxx_p…
NikitaZotov Feb 3, 2025
51ebdba
[docs] Add launching Python problem solver in quick start
NikitaZotov Feb 3, 2025
82578f7
[config] Add ellipsis config
NikitaZotov Feb 3, 2025
8c84e49
[solver][refactor] Format code
NikitaZotov Feb 3, 2025
13464c4
[ci] Leave TODO about need to test Python problem solver
NikitaZotov Feb 3, 2025
d77bf1f
[docs] Remove outdated comment from CONTRIBUTING.md
NikitaZotov Feb 3, 2025
f15d42e
[kb][refactor] Fix indentions in component specification
NikitaZotov Feb 4, 2025
45da0b1
[ci] Fix newline in tests ci
NikitaZotov Feb 4, 2025
afef674
[cmake] Move error about Windows to the first lines
NikitaZotov Feb 4, 2025
779020e
[docs] Fix incorrects in CONTRIBUTING.md
NikitaZotov Feb 4, 2025
965425c
[docs] Add newline in assets
NikitaZotov Feb 4, 2025
72e753f
[docs] Fix port for docs
NikitaZotov Feb 4, 2025
c6b9595
[docs] Fix paths to sc-machine binaries
NikitaZotov Feb 4, 2025
174b758
[scripts] Fix version variable name for sc-component-manager
NikitaZotov Feb 4, 2025
47cebf8
[docs] Fix incorrects in quick start
NikitaZotov Feb 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
91 changes: 91 additions & 0 deletions .github/workflows/check_style.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
name: Style

on:
pull_request:
branches: [main]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
check_pr_commits:
name: Check commit messages
runs-on: ubuntu-24.04

steps:
- name: GS Commit Message Checker
# You may pin to the exact commit or the version.
# uses: GsActions/commit-message-checker@9d8708beab99f811c5fe3a4f98acc4b2f2ba8496
uses: GsActions/commit-message-checker@v2
with:
# A regex pattern to check if a commit message is valid.
pattern: "((\\[(changelog|ci|config|doc|docs|test|tests|kb|solver|interface|review|refactor|scripts|git|cmake|build)\\])+(.)+)|(Review fixes)$"
# Expression flags change how the expression is interpreted.
flags: # optional, default is gm
# A error message which will be returned in case of an error.
error: "One of commit messages or PR title have incorrect formatting. Please read the documentation: https://github.com/ostis-ai/ostis-metasystem/blob/main/CONTRIBUTING.md"
# Setting this input to true will exclude the Pull Request title from the check.
excludeTitle: true # optional, default is false
# Setting this input to true will exclude the Pull Request description from the check.
excludeDescription: true # optional, default is false
# Setting this input to true will check all Pull Request commits
checkAllCommitMessages: true # optional, default is false
# you must provide GITHUB_TOKEN to this input if checkAllCommitMessages is true
accessToken: ${{ secrets.GITHUB_TOKEN }}

check_formatting:
name: Check formatting
runs-on: ubuntu-24.04

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Restore ccache caches
uses: hendrikmuhs/[email protected]
with:
key: ${{ github.job }}

- name: Conan cache
uses: actions/cache@v4
with:
path: ~/.conan/data
key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }}

- name: apt cache
uses: actions/cache@v4
with:
path: |
/var/cache/apt/
/var/lib/apt/
key: apt-${{ runner.os }}-${{ github.job }}

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.12"

- name: Set up pipx
run: |
python -m pip install --user pipx
python -m pipx ensurepath

- name: Set up Conan
run: |
pipx install cmake
pipx install conan

- name: Install compilers
run: sudo apt install build-essential ninja-build ccache

- name: Set Conan remote
run: |
conan profile detect
conan remote add ostis-ai https://conan.ostis.net/artifactory/api/conan/ostis-ai-sc-machine/

- name: Install sc-machine
run: conan install . --build=missing

- name: Checking the code with clang
run: |
./scripts/clang/check_formatting.sh
15 changes: 15 additions & 0 deletions .github/workflows/docs_deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Deploy docs
on:
push:
branches:
- main
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.12
- run: pip3 install mkdocs-material
- run: mkdocs gh-deploy --force
46 changes: 0 additions & 46 deletions .github/workflows/main.yml

This file was deleted.

100 changes: 97 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,115 @@ on:
workflow_dispatch:

jobs:
build:
tests-conan:
uses: ./.github/workflows/test_conan.yml
build-conan:
needs: tests-conan
strategy:
fail-fast: true
matrix:
config:
- { os: ubuntu-22.04, cc: "gcc", cxx: "g++" }
- { os: macos-14, cc: "clang", cxx: "clang++" }

runs-on: ${{ matrix.config.os }}

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Restore ccache caches
uses: hendrikmuhs/[email protected]
with:
key: ${{ github.job }}

- name: Conan cache
uses: actions/cache@v4
with:
path: ~/.conan/data
key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }}

- name: apt cache
uses: actions/cache@v4
if: runner.os == 'Linux'
with:
path: |
/var/cache/apt/
/var/lib/apt/
key: apt-${{ runner.os }}-${{ github.job }}

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.12"

- name: Set up pipx
run: |
python -m pip install --user pipx
python -m pipx ensurepath

- name: Set up Conan
run: |
pipx install cmake
pipx install conan

- name: Install compilers (Ubuntu)
if: runner.os == 'Linux'
run: sudo apt install build-essential ninja-build ccache

- name: Install compilers (macOS)
if: runner.os == 'macOS'
run: brew install cmake ninja ccache

- name: Set Conan remote
run: |
conan profile detect
conan remote add ostis-ai https://conan.ostis.net/artifactory/api/conan/ostis-ai-sc-machine/

- name: Install sc-machine
run: conan install . --build=missing

- name: Build ostis-metasystem
id: run_cmake
run: |
cmake --preset release-conan
cmake --build --preset release

- name: Create archive
run: |
cd ./build/Release
cpack -G TGZ

- name: Upload archive
uses: actions/upload-artifact@v4
with:
name: ostis-metasystem-${{ matrix.config.os }}-${{ github.ref_name }}
path: ./build/Release/ostis-metasystem-*.tar.gz

changelog:
needs: build-conan
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Read changlog
- name: Read changelog
id: changelog_reader
uses: mindsers/changelog-reader-action@v2
with:
version: ${{ github.ref_name }}
path: docs/changelog.md

- name: Download artifacts
uses: actions/download-artifact@v4
with:
pattern: ostis-metasystem-*
path: artifacts

- name: Release
uses: softprops/action-gh-release@v1
with:
body: ${{ steps.changelog_reader.outputs.changes }}
name: 'v${{ github.ref_name }}'
files: |
artifacts/**/*.tar.gz
81 changes: 81 additions & 0 deletions .github/workflows/test_conan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
name: Tests (Conan)

on:
pull_request:
branches: [main]
workflow_call:

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

jobs:
run_tests:
name: Conan build
runs-on: ubuntu-24.04

strategy:
fail-fast: false
matrix:
config:
- { cc: "gcc", cxx: "g++" }

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Restore ccache caches
uses: hendrikmuhs/[email protected]
with:
key: ${{ github.job }}

- name: Conan cache
uses: actions/cache@v4
with:
path: ~/.conan/data
key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }}

- name: apt cache
uses: actions/cache@v4
with:
path: |
/var/cache/apt/
/var/lib/apt/
key: apt-${{ runner.os }}-${{ github.job }}

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.12"

- name: Set up pipx
run: |
python -m pip install --user pipx
python -m pipx ensurepath

- name: Set up Conan
run: |
pipx install cmake
pipx install conan

- name: Install compilers
run: sudo apt install build-essential ninja-build

- name: Set Conan remote
run: |
conan profile detect
conan remote add ostis-ai https://conan.ostis.net/artifactory/api/conan/ostis-ai-sc-machine/

- name: Install sc-machine
run: conan install . --build=missing

- name: Build ostis-metasystem with tests
id: run_cmake
run: |
cmake --preset release-with-tests-conan
cmake --build --preset release

# TODO(NikitaZotov): test Python problem solver

- name: Run ostis-metasystem tests
id: run_tests
run: cd build/Release && ctest -V
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ cmake-build-debug
cmake-build-release
/build
/bin
/install
repo
/ConanPresets.json

.venv
*.pyc
Expand Down Expand Up @@ -36,5 +39,3 @@ sc-server.log
*.synctex.gz

*.db

platform-dependent-components/interface/react-sc-web
10 changes: 3 additions & 7 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
[submodule "ostis-web-platform"]
path = ostis-web-platform
url = https://github.com/ostis-ai/ostis-web-platform
branch = develop
[submodule "docs/scn"]
path = docs/scn
url = https://github.com/ostis-ai/scn-latex-plugin
[submodule "thirdparty/googletest"]
path = thirdparty/googletest
url = https://github.com/google/googletest.git
[submodule "platform-dependent-components/interface/react-sc-web"]
path = platform-dependent-components/interface/react-sc-web
url = https://github.com/ostis-ai/react-sc-web.git
Loading
Loading