Skip to content

Commit

Permalink
Merge pull request #19 from MRNIU/master-engine
Browse files Browse the repository at this point in the history
Master engine
  • Loading branch information
MRNIU authored Oct 30, 2023
2 parents 2e237ae + fbbaa49 commit a8df3b9
Show file tree
Hide file tree
Showing 2,094 changed files with 8,949 additions and 177,519 deletions.
12 changes: 12 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@

# This file is a part of Simple-XX/SimplePhysicsEngine
# (https://github.com/Simple-XX/SimplePhysicsEngine).
#
# CMakeLists.txt for Simple-XX/SimplePhysicsEngine.

---
# @version clang-format version 15
# @see https://clang.llvm.org/docs/ClangFormatStyleOptions.html
# 使用 LLVM 规范
BasedOnStyle: LLVM
...
28 changes: 28 additions & 0 deletions .clang-tidy
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@

# This file is a part of Simple-XX/SimplePhysicsEngine
# (https://github.com/Simple-XX/SimplePhysicsEngine).
#
# .clang-tidy for Simple-XX/SimplePhysicsEngine.

---
Checks: '-*,\
bugprone-*,\
clang-analyzer-*,\
cppcoreguidelines-*,\
hicpp-*,\
llvm-*,\
misc-*
modernize-*,\
performance-*,\
portability-*,\
readability-*,\
-cppcoreguidelines-pro-type-reinterpret-cast,\
-bugprone-easily-swappable-parameters,\
-llvm-header-guard,\
-misc-non-private-member-variables-in-classes,\
-cppcoreguidelines-non-private-member-variables-in-classes,\
-readability-identifier-length,\
-cppcoreguidelines-avoid-non-const-global-variables'
HeaderFilterRegex: '^${sourceDir}/src'
AnalyzeTemporaryDtors: true
...
81 changes: 81 additions & 0 deletions .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# This file is a part of Simple-XX/SimplePhysicsEngine
# (https://github.com/Simple-XX/SimplePhysicsEngine).
#
# workflow.yml for Simple-XX/SimplePhysicsEngine.

name: build

on:
- push
- pull_request
- release

env:
CMAKE_BUILD_TYPE: Release

jobs:
build_docs:
name: Build and publish documentation
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3

- name: Install dependencies
run: |
sudo apt update
sudo apt install --fix-missing -y doxygen graphviz clang-format clang-tidy cppcheck lcov
sudo apt install --fix-missing -y gcc g++ libspdlog-dev
- name: Build
run: |
cmake --preset=build
cmake --build build --target doc
- name: Publish
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ${{github.workspace}}/doc/html

build_ubuntu:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Install dependencies
run: |
sudo apt update
sudo apt install --fix-missing -y doxygen graphviz clang-format clang-tidy cppcheck lcov
sudo apt install --fix-missing -y gcc g++ libspdlog-dev
- name: Build
run: |
cmake --preset=build
cmake --build build --target all
cmake --build build --target coverage
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
with:
files: build/coverage/coverage.info
verbose: true

build_macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3

- name: Install dependencies
run: |
brew install doxygen graphviz llvm cppcheck lcov
ln -s "$(brew --prefix llvm)/bin/clang-format" "/usr/local/bin/clang-format"
ln -s "$(brew --prefix llvm)/bin/clang-tidy" "/usr/local/bin/clang-tidy"
brew install gcc g++ sdl2 sdl2_ttf libomp
- name: Build
run: |
cmake --preset=build
cmake --build build --target all
cmake --build build --target coverage
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,6 @@ include(3rd)
include(project_config)
include(compile_config)

add_subdirectory(engine)
# add_subdirectory(demo2d)
# add_subdirectory(demo3d)
add_subdirectory(src)
add_subdirectory(test)
add_subdirectory(doc)
19 changes: 0 additions & 19 deletions _deps/eigen/Eigen/CMakeLists.txt

This file was deleted.

46 changes: 0 additions & 46 deletions _deps/eigen/Eigen/Cholesky

This file was deleted.

48 changes: 0 additions & 48 deletions _deps/eigen/Eigen/CholmodSupport

This file was deleted.

Loading

0 comments on commit a8df3b9

Please sign in to comment.