Skip to content

Commit

Permalink
Merge branch 'FreeCAD:main' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
sasobadovinac authored Sep 1, 2024
2 parents e2c0688 + 2a9cf9e commit eafcbcb
Show file tree
Hide file tree
Showing 1,334 changed files with 194,450 additions and 166,545 deletions.
5 changes: 4 additions & 1 deletion .clang-tidy
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@
Checks: 'clang-diagnostic-*,clang-analyzer-*,boost-*,bugprone-*,
performance-*,readability-*,portability-*,modernize-*,cppcoreguidelines-*,google-explicit-constructor,
concurrency-*,-modernize-use-trailing-return-type, -modernize-use-nodiscard,
-readability-redundant-access-specifiers,-readability-qualified-auto'
-readability-redundant-access-specifiers,-readability-qualified-auto,
-cppcoreguidelines-avoid-non-const-global-variables,-cppcoreguidelines-owning-memory,
-readability-convert-member-functions-to-static,-bugprone-easily-swappable-parameters,
-cppcoreguidelines-pro-type-static-cast-downcast'
WarningsAsErrors: ''
HeaderFilterRegex: ''
AnalyzeTemporaryDtors: false
Expand Down
16 changes: 8 additions & 8 deletions .github/ISSUE_TEMPLATE/PROBLEM_REPORT.yml
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
name: Report a Problem
description: Have you found something that does not work well, is too hard to do or is missing altogether? Please create a Problem Report.
labels: ["needs triage"]
labels: ["Status: Needs triage"]
body:
- type: checkboxes
id: existing_issue
attributes:
label: Is there an existing issue for this?
description: Please search to see if an issue already exists for the problem you encountered.
description: Please [search](https://github.com/FreeCAD/FreeCAD/issues) to see if a similar issue already exists for the problem you encountered.
options:
- label: I have searched the existing issues
required: true
- type: textarea
id: description
attributes:
label: Problem description
description: Describe the problem and how it impacts user experience, workflow, maintainability or speed of the code. If the problem appears to be a bug with the current functionality, provide as test case or recipe that reproduces the error.
description: Describe the problem and how it impacts user experience, workflow, maintainability or speed of the code. If the problem appears to be a bug with the current functionality, provide as test case or recipe that reproduces the error. Ideally record a macro and attach it.
placeholder: Description of the problem
validations:
required: true
Expand All @@ -33,22 +33,21 @@ body:
options:
- Addon Manager
- Assembly
- BIM/Arch
- CAM/Path
- BIM
- CAM
- Core
- Draft
- Expressions
- FEM
- File formats
- GCS
- Mesh
- OpenSCAD
- Part
- PartDesign
- Project Tools & Websites
- Sketcher
- Spreadsheet
- Techdraw
- TechDraw
- Other (specify in description)
- type: textarea
id: anything_else
Expand All @@ -57,6 +56,7 @@ body:
description: |
Links? References? Anything that will give us more context about the issue you are encountering!
If there is a discussion about the problem on the forum, provide link(s) here.
You can upload or copy your macro here to speed up the diagnosis and debugging.
Tip: You can attach images or log files by clicking this area to highlight it and then dragging files in. To attach a FCStd file, ZIP it first (GitHub won't recognize the extension otherwise).
validations:
Expand All @@ -65,7 +65,7 @@ body:
id: terms
attributes:
label: Code of Conduct
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/FreeCAD/FreeCAD/blob/master/CODE_OF_CONDUCT.md)
description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/FreeCAD/FreeCAD/blob/main/CODE_OF_CONDUCT.md)
options:
- label: I agree to follow this project's Code of Conduct
required: true
18 changes: 18 additions & 0 deletions .github/labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
# source:
# - any: ['src/**/*', '!src/docs/*']

# 'Mod' related labels

"Mod: Core":
- changed-files:
- any-glob-to-any-file: ['src/App/**/*', 'src/Base/**/*', 'src/Gui/**/*']
Expand All @@ -18,6 +20,10 @@
- changed-files:
- any-glob-to-any-file: ['src/Mod/Material/**/*']

"Mod: Measurement":
- changed-files:
- any-glob-to-any-file: ['src/Mod/Measure/**/*']

"Mod: BIM":
- changed-files:
- any-glob-to-any-file: ['src/Mod/BIM/**/*']
Expand Down Expand Up @@ -85,3 +91,15 @@
"Mod: Test":
- changed-files:
- any-glob-to-any-file: ['src/Mod/Test/**/*']

# 'Packaging' related labels

"Packaging/building":
- changed-files:
- any-glob-to-any-file: ['cMake/**/*']

# 'Topic' related labels

"Topic: Stylesheets":
- changed-files:
- any-glob-to-any-file: ['src/Gui/Stylesheets/**/*']
19 changes: 13 additions & 6 deletions .github/workflows/CI_master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,17 +63,24 @@ jobs:
with:
artifactBasename: Ubuntu_22-04_Conda-${{ github.run_id }}

Ubuntu_22-04_Conda_Qt6:
needs: [Prepare]
uses: ./.github/workflows/sub_buildUbuntu2204CondaQt6.yml
with:
artifactBasename: Ubuntu_22-04_Conda-Qt6-${{ github.run_id }}

Windows:
needs: [Prepare]
uses: ./.github/workflows/sub_buildWindows.yml
with:
artifactBasename: Windows-${{ github.run_id }}

Windows_Conda:
needs: [Prepare]
uses: ./.github/workflows/sub_buildWindowsConda.yml
with:
artifactBasename: Windows_Conda-${{ github.run_id }}
## Disable until the following issue is resolved: https://github.com/mamba-org/mamba/issues/3292
# Windows_Conda:
# needs: [Prepare]
# uses: ./.github/workflows/sub_buildWindowsConda.yml
# with:
# artifactBasename: Windows_Conda-${{ github.run_id }}

Lint:
needs: [Prepare]
Expand All @@ -92,7 +99,7 @@ jobs:
Ubuntu_20-04,
Ubuntu_22-04_Conda,
Windows,
Windows_Conda,
# Windows_Conda,
Lint
]
if: always()
Expand Down
210 changes: 210 additions & 0 deletions .github/workflows/sub_buildUbuntu2204CondaQt6.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,210 @@
# SPDX-License-Identifier: LGPL-2.1-or-later
# ***************************************************************************
# * *
# * Copyright (c) 2023 0penBrain. *
# * *
# * This file is part of FreeCAD. *
# * *
# * FreeCAD is free software: you can redistribute it and/or modify it *
# * under the terms of the GNU Lesser General Public License as *
# * published by the Free Software Foundation, either version 2.1 of the *
# * License, or (at your option) any later version. *
# * *
# * FreeCAD is distributed in the hope that it will be useful, but *
# * WITHOUT ANY WARRANTY; without even the implied warranty of *
# * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
# * Lesser General Public License for more details. *
# * *
# * You should have received a copy of the GNU Lesser General Public *
# * License along with FreeCAD. If not, see *
# * <https://www.gnu.org/licenses/>. *
# * *
# ***************************************************************************

# This is a build and test workflow for CI of FreeCAD.
# This workflow aims at building and testing FreeCAD on a Conda environment on Linux.

name: Build Ubuntu 22.04 (Conda)
on:
workflow_call:
inputs:
artifactBasename:
type: string
required: true
testOnBuildDir:
default: false
type: boolean
required: false
allowedToFail:
default: false
type: boolean
required: false
outputs:
reportFile:
value: ${{ jobs.Build.outputs.reportFile }}

jobs:
Build:
runs-on: ubuntu-22.04
continue-on-error: ${{ inputs.allowedToFail }}
env:
CCACHE_DIR: ${{ github.workspace }}/ccache
CCACHE_CONFIGPATH: ${{ github.workspace }}/ccache/config
CCACHE_MAXSIZE: 1G
CCACHE_COMPILERCHECK: "%compiler% -dumpfullversion -dumpversion" # default:mtime
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 1
builddir: ${{ github.workspace }}/build/release/
logdir: /tmp/logs/
reportdir: /tmp/report/
reportfilename: ${{ inputs.artifactBasename }}-report.md
defaults:
run:
shell: bash -l {0}
outputs:
reportFile: ${{ steps.Init.outputs.reportFile }}

steps:
- name: Checking out source code
uses: actions/checkout@v4
with:
submodules: true
- name: Setup Miniconda
env:
CONDA_VERBOSITY: 2
uses: conda-incubator/setup-miniconda@v3
with:
activate-environment: .conda/freecad
environment-file: conda/conda-env-qt6.yaml
channels: conda-forge,defaults
channel-priority: true
miniforge-version: latest
- name: Install FreeCAD dependencies
env:
CONDA_VERBOSITY: 2
run: |
sudo apt-get update -qq
sudo apt-get install -y --no-install-recommends \
libegl1 \
libgl1 \
libglx0 \
libopengl0
./conda/setup-environment-qt6.sh
- name: Set Environment Variables
run: |
echo "CC=$CC" >> "$GITHUB_ENV"
echo "CXX=$CXX" >> "$GITHUB_ENV"
- name: Make needed directories, files and initializations
id: Init
run: |
mkdir -p ${{ env.CCACHE_DIR }}
mkdir -p ${{ env.CCACHE_CONFIGPATH }}
mkdir -p ${{ env.builddir }}
mkdir -p ${{ env.logdir }}
mkdir -p ${{ env.reportdir }}
echo "reportFile=${{ env.reportfilename }}" >> $GITHUB_OUTPUT
- name: Generate cache key
id: genCacheKey
uses: ./.github/workflows/actions/linux/generateCacheKey
with:
compiler: ${{ env.CXX }}
- name: Restore Compiler Cache
uses: actions/cache@v4
with:
save-always: true
path: ${{ env.CCACHE_DIR }}
key: FC-${{ steps.genCacheKey.outputs.cacheKey }}-${{ github.ref }}-${{ github.run_id }}-qt6
restore-keys: |
FC-${{ steps.genCacheKey.outputs.cacheKey }}-${{ github.ref }}-qt6-
FC-${{ steps.genCacheKey.outputs.cacheKey }}-qt6-
- name: Print CCache statistics before build, reset stats and print config
run: |
ccache -s
ccache -z
ccache -p
- name: CMake Configure
uses: ./.github/workflows/actions/linux/configure
with:
extraParameters: >
--preset conda-linux-release
-DCMAKE_INSTALL_PREFIX=${{ github.workspace }}/.conda/freecad/opt/freecad
-DQT_HOST_PATH=${{ github.workspace }}/.conda/freecad/
-DFREECAD_QT_VERSION=6
-DBUILD_REVERSEENGINEERING=OFF
builddir: ${{ env.builddir }}
logFile: ${{ env.logdir }}Cmake.log
errorFile: ${{ env.logdir }}CmakeErrors.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: CMake Build
uses: ./.github/workflows/actions/linux/build
with:
builddir: ${{ env.builddir }}
logFile: ${{ env.logdir }}Build.log
errorFile: ${{ env.logdir }}BuildErrors.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: Print ccache statistics after Build
run: |
ccache -s
- name: FreeCAD CLI tests on build dir
if: inputs.testOnBuildDir
timeout-minutes: 10
uses: ./.github/workflows/actions/runPythonTests
with:
testDescription: "CLI tests on build dir"
testCommand: ${{ env.builddir }}/bin/FreeCADCmd -t 0
logFile: ${{ env.logdir }}TestCLIBuild.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: FreeCAD GUI tests on build dir
if: inputs.testOnBuildDir
timeout-minutes: 15
uses: ./.github/workflows/actions/runPythonTests
with:
testDescription: "GUI tests on build dir"
testCommand: xvfb-run ${{ env.builddir }}/bin/FreeCAD -t 0
logFile: ${{ env.logdir }}TestGUIBuild.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: C++ tests
timeout-minutes: 1
uses: ./.github/workflows/actions/runCPPTests/runAllTests
with:
reportdir: ${{ env.reportdir }}
builddir: ${{ env.builddir }}
reportFile: ${{ env.reportdir }}${{ env.reportfilename }}
- name: CMake Install
uses: ./.github/workflows/actions/linux/install
with:
builddir: ${{ env.builddir }}
logFile: ${{ env.logdir }}Install.log
errorFile: ${{ env.logdir }}InstallErrors.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: FreeCAD CLI tests on install
timeout-minutes: 10
uses: ./.github/workflows/actions/runPythonTests
with:
testDescription: "CLI tests on install"
testCommand: ${{ github.workspace }}/.conda/freecad/opt/freecad/bin/FreeCADCmd -t 0
logFile: ${{ env.logdir }}TestCLIInstall.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: FreeCAD GUI tests on install
timeout-minutes: 15
uses: ./.github/workflows/actions/runPythonTests
with:
testDescription: "GUI tests on install"
testCommand: xvfb-run ${{ github.workspace }}/.conda/freecad/opt/freecad/bin/FreeCAD -t 0
logFile: ${{ env.logdir }}TestGUIInstall.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: Upload logs
if: always()
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.artifactBasename }}-Logs
path: |
${{ env.logdir }}
/var/crash/*FreeCAD*
- name: Upload report
if: always()
uses: actions/upload-artifact@v4
with:
name: ${{ env.reportfilename }}
path: |
${{env.reportdir}}${{ env.reportfilename }}
6 changes: 3 additions & 3 deletions .github/workflows/sub_lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ on:
type: boolean
required: false
cpplintFilters:
default: -build/c++17,-build/header_guard,-build/include,-build/include_alpha,-build/include_order,-build/include_subdir,-build/include_what_you_use,-build/namespaces,-legal/copyright,-readability/braces,-readability-braces-around-statements,-readability/casting,-readability/namespace,-readability/todo,-runtime/indentation_namespace,-runtime/int,-runtime/references,-whitespace/blank_line,-whitespace/braces,-whitespace/comma,-whitespace/comments,-whitespace/end_of_line,-whitespace/indent,-whitespace/line_length,-whitespace/newline,-whitespace/operators,-whitespace/parens,-whitespace/semicolon,-whitespace/tab,-whitespace/todo
default: -whitespace-*
type: string
required: false
cpplintLineLength:
Expand Down Expand Up @@ -153,7 +153,7 @@ on:
type: boolean
required: false
clazyChecks:
default: level1
default: level2,no-non-pod-global-static,no-copyable-polymorphic
type: string
required: false
clazyFailSilent:
Expand All @@ -169,7 +169,7 @@ on:
type: string
required: false
QT6Branch: # branch to check for QT6 Porting
default: master
default: main
type: string
required: false
clazyQT6FailSilent:
Expand Down
Loading

0 comments on commit eafcbcb

Please sign in to comment.