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

Fix Godot 4.0 compile errors, update JavaScript integration, refactor code, and address minor issues #156

Merged
merged 62 commits into from
Oct 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
783517a
Update README.md
ogrotten Oct 21, 2022
01457b9
Fix Godot 4.0 compile errors, update JavaScript integration, refactor…
fire Apr 23, 2023
398a108
Update generate_builtin_api.py, javascript.cpp, javascript.h, and 13 …
fire Jun 15, 2023
847fe10
Remove build_github_actions.py
fire Jun 15, 2023
caa8840
Update godot-javascript to better pass tests.
fire Jun 15, 2023
3f6a3b4
Remove pthread library and run format.
fire Jun 15, 2023
e547560
Format binding generator.
fire Jun 15, 2023
7655597
Apply formatting.
fire Jun 15, 2023
53f4051
Apply python formatting.
fire Jun 15, 2023
bcaa414
Add a condition to avoid building javascript on msvc.
fire Jun 15, 2023
e3e97ba
Disable unit tests.
fire Jun 15, 2023
4dad363
Remove c++ version check.
fire Jun 15, 2023
537e2b4
Avoid extras.
fire Jun 15, 2023
5261a4f
Only build windows and linux.
fire Jun 15, 2023
1c75361
Move versions back to 4.0.
fire Jun 18, 2023
9dabb22
Fix error in includes.
fire Jun 18, 2023
b87a29e
git subrepo pull (merge) modules/javascript
fire Jun 18, 2023
f430ed2
Handle cases that aren't supported.
fire Jun 18, 2023
f6687c5
git subrepo pull (merge) modules/javascript
fire Jun 18, 2023
245f8d0
Update scons.
fire Jun 18, 2023
166c796
Force a tag.
fire Jun 19, 2023
087e244
git subrepo pull (merge) modules/javascript
fire Jun 19, 2023
17caa75
Switch to match master.
fire Jun 19, 2023
23ba457
Update build scripts.
fire Jun 19, 2023
0919fc3
Add pthread for mingw.
fire Jun 19, 2023
78dbf97
If use mingw, use pthread.
fire Jun 19, 2023
eca30e6
Restore file format.
fire Jun 19, 2023
a91c1f4
Restore header guards too.
fire Jun 19, 2023
fdd5180
Fix include guards style.
fire Jun 19, 2023
8d976e4
Restore black format.
fire Jun 19, 2023
f4bc581
Restore all the scripts.
fire Jun 19, 2023
48305ba
Add python build.
fire Jun 19, 2023
01abd78
Remove python tests.
fire Jun 19, 2023
f648c5b
Disabled a few builds.
fire Jun 19, 2023
5b66370
feat: add icons
jaune Aug 19, 2023
2911768
Revert "Disabled a few builds."
fire Jun 19, 2023
d3ebf68
Update XML file paths for JavaScript and JavaScriptModule classes
fire Aug 20, 2023
007e94a
Refactor JavaScript bindings and fix file paths
fire Aug 20, 2023
dfbdf57
Format SCsub.
fire Aug 20, 2023
0fe880e
Update the readme.
fire Aug 20, 2023
1bb9edf
Format black_format.sh and SCsub scripts
fire Aug 20, 2023
0b9283b
Add XML schema for class documentation
fire Aug 20, 2023
5fd3ce9
Refactor static checks workflow
fire Aug 20, 2023
d5a9cf7
Refactor static checks workflow
fire Aug 20, 2023
6177b3e
Add .clang-format and .clang-tidy configuration files
fire Aug 24, 2023
94d95b5
Apply formatting.
fire Aug 24, 2023
76692da
Apply whitespace change.
fire Aug 24, 2023
3863950
Run spell checker.
fire Aug 24, 2023
ec74bb0
Refactor platform condition in config.py
fire Aug 24, 2023
5bf37c6
Remove JavaScript style checks
fire Aug 24, 2023
71c6704
Update JSValue typedef in quickjs.h to avoid error.
fire Aug 24, 2023
8d86711
Support MSVC builds without error in Github Actions.
fire Aug 24, 2023
221e358
Fix function name and use safer string formatting in JavaScript module
fire Aug 24, 2023
d487bcf
Format python files for automated tests.
fire Aug 24, 2023
b2cacc0
Fix gitub actions tests.
fire Aug 24, 2023
c2533ae
Fix tests.
fire Aug 24, 2023
60db283
Try to pass tests.
fire Aug 24, 2023
45ca44b
Exclude mono platform
fire Aug 24, 2023
483c70d
Apply xml docs fixes for tests.
fire Aug 24, 2023
ca34e79
Merge pull request #160 from jaune/gd4-icons
fire Aug 31, 2023
7160c86
Refactor JavaScript integration and improve code readability.
fire Oct 1, 2023
7fecf15
Merge pull request #164 from nmerget/fix-gd4-rebase-2
fire Oct 1, 2023
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
199 changes: 199 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
# Commented out parameters are those with the same value as base LLVM style.
# We can uncomment them if we want to change their value, or enforce the
# chosen value in case the base style changes (last sync: Clang 14.0).
---
### General config, applies to all languages ###
BasedOnStyle: LLVM
AccessModifierOffset: -4
AlignAfterOpenBracket: DontAlign
# AlignArrayOfStructures: None
# AlignConsecutiveMacros: None
# AlignConsecutiveAssignments: None
# AlignConsecutiveBitFields: None
# AlignConsecutiveDeclarations: None
# AlignEscapedNewlines: Right
AlignOperands: DontAlign
AlignTrailingComments: false
# AllowAllArgumentsOnNextLine: true
AllowAllParametersOfDeclarationOnNextLine: false
# AllowShortEnumsOnASingleLine: true
# AllowShortBlocksOnASingleLine: Never
# AllowShortCaseLabelsOnASingleLine: false
# AllowShortFunctionsOnASingleLine: All
# AllowShortLambdasOnASingleLine: All
# AllowShortIfStatementsOnASingleLine: Never
# AllowShortLoopsOnASingleLine: false
# AlwaysBreakAfterDefinitionReturnType: None
# AlwaysBreakAfterReturnType: None
# AlwaysBreakBeforeMultilineStrings: false
# AlwaysBreakTemplateDeclarations: MultiLine
# AttributeMacros:
# - __capability
# BinPackArguments: true
# BinPackParameters: true
# BraceWrapping:
# AfterCaseLabel: false
# AfterClass: false
# AfterControlStatement: Never
# AfterEnum: false
# AfterFunction: false
# AfterNamespace: false
# AfterObjCDeclaration: false
# AfterStruct: false
# AfterUnion: false
# AfterExternBlock: false
# BeforeCatch: false
# BeforeElse: false
# BeforeLambdaBody: false
# BeforeWhile: false
# IndentBraces: false
# SplitEmptyFunction: true
# SplitEmptyRecord: true
# SplitEmptyNamespace: true
# BreakBeforeBinaryOperators: None
# BreakBeforeConceptDeclarations: true
# BreakBeforeBraces: Attach
# BreakBeforeInheritanceComma: false
# BreakInheritanceList: BeforeColon
# BreakBeforeTernaryOperators: true
# BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: AfterColon
# BreakStringLiterals: true
ColumnLimit: 0
# CommentPragmas: '^ IWYU pragma:'
# QualifierAlignment: Leave
# CompactNamespaces: false
ConstructorInitializerIndentWidth: 8
ContinuationIndentWidth: 8
Cpp11BracedListStyle: false
# DeriveLineEnding: true
# DerivePointerAlignment: false
# DisableFormat: false
# EmptyLineAfterAccessModifier: Never
# EmptyLineBeforeAccessModifier: LogicalBlock
# ExperimentalAutoDetectBinPacking: false
# PackConstructorInitializers: BinPack
ConstructorInitializerAllOnOneLineOrOnePerLine: true
# AllowAllConstructorInitializersOnNextLine: true
# FixNamespaceComments: true
# ForEachMacros:
# - foreach
# - Q_FOREACH
# - BOOST_FOREACH
# IfMacros:
# - KJ_IF_MAYBE
# IncludeBlocks: Preserve
IncludeCategories:
- Regex: '".*"'
Priority: 1
- Regex: '^<.*\.h>'
Priority: 2
- Regex: '^<.*'
Priority: 3
# IncludeIsMainRegex: '(Test)?$'
# IncludeIsMainSourceRegex: ''
# IndentAccessModifiers: false
IndentCaseLabels: true
# IndentCaseBlocks: false
# IndentGotoLabels: true
# IndentPPDirectives: None
# IndentExternBlock: AfterExternBlock
# IndentRequires: false
IndentWidth: 4
# IndentWrappedFunctionNames: false
# InsertTrailingCommas: None
# JavaScriptQuotes: Leave
# JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: false
# LambdaBodyIndentation: Signature
# MacroBlockBegin: ''
# MacroBlockEnd: ''
# MaxEmptyLinesToKeep: 1
# NamespaceIndentation: None
# PenaltyBreakAssignment: 2
# PenaltyBreakBeforeFirstCallParameter: 19
# PenaltyBreakComment: 300
# PenaltyBreakFirstLessLess: 120
# PenaltyBreakOpenParenthesis: 0
# PenaltyBreakString: 1000
# PenaltyBreakTemplateDeclaration: 10
# PenaltyExcessCharacter: 1000000
# PenaltyReturnTypeOnItsOwnLine: 60
# PenaltyIndentedWhitespace: 0
# PointerAlignment: Right
# PPIndentWidth: -1
# ReferenceAlignment: Pointer
# ReflowComments: true
# RemoveBracesLLVM: false
# SeparateDefinitionBlocks: Leave
# ShortNamespaceLines: 1
# SortIncludes: CaseSensitive
# SortJavaStaticImport: Before
# SortUsingDeclarations: true
# SpaceAfterCStyleCast: false
# SpaceAfterLogicalNot: false
# SpaceAfterTemplateKeyword: true
# SpaceBeforeAssignmentOperators: true
# SpaceBeforeCaseColon: false
# SpaceBeforeCpp11BracedList: false
# SpaceBeforeCtorInitializerColon: true
# SpaceBeforeInheritanceColon: true
# SpaceBeforeParens: ControlStatements
# SpaceBeforeParensOptions:
# AfterControlStatements: true
# AfterForeachMacros: true
# AfterFunctionDefinitionName: false
# AfterFunctionDeclarationName: false
# AfterIfMacros: true
# AfterOverloadedOperator: false
# BeforeNonEmptyParentheses: false
# SpaceAroundPointerQualifiers: Default
# SpaceBeforeRangeBasedForLoopColon: true
# SpaceInEmptyBlock: false
# SpaceInEmptyParentheses: false
# SpacesBeforeTrailingComments: 1
# SpacesInAngles: Never
# SpacesInConditionalStatement: false
# SpacesInContainerLiterals: true
# SpacesInCStyleCastParentheses: false
## Godot TODO: We'll want to use a min of 1, but we need to see how to fix
## our comment capitalization at the same time.
SpacesInLineCommentPrefix:
Minimum: 0
Maximum: -1
# SpacesInParentheses: false
# SpacesInSquareBrackets: false
# SpaceBeforeSquareBrackets: false
# BitFieldColonSpacing: Both
# StatementAttributeLikeMacros:
# - Q_EMIT
# StatementMacros:
# - Q_UNUSED
# - QT_REQUIRE_VERSION
TabWidth: 4
# UseCRLF: false
UseTab: Always
# WhitespaceSensitiveMacros:
# - STRINGIZE
# - PP_STRINGIZE
# - BOOST_PP_STRINGIZE
# - NS_SWIFT_NAME
# - CF_SWIFT_NAME
---
### C++ specific config ###
Language: Cpp
Standard: c++17
---
### ObjC specific config ###
Language: ObjC
# ObjCBinPackProtocolList: Auto
ObjCBlockIndentWidth: 4
# ObjCBreakBeforeNestedBlockParam: true
# ObjCSpaceAfterProperty: false
# ObjCSpaceBeforeProtocolList: true
---
### Java specific config ###
Language: Java
# BreakAfterJavaFieldAnnotations: false
JavaImportGroups: ['org.godotengine', 'android', 'androidx', 'com.android', 'com.google', 'java', 'javax']
...
47 changes: 47 additions & 0 deletions .clang-tidy
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
Checks: 'clang-diagnostic-*,clang-analyzer-*,-*,cppcoreguidelines-pro-type-member-init,modernize-redundant-void-arg,modernize-use-bool-literals,modernize-use-default-member-init,modernize-use-nullptr,readability-braces-around-statements,readability-redundant-member-init'
WarningsAsErrors: ''
HeaderFilterRegex: ''
AnalyzeTemporaryDtors: false
FormatStyle: none
CheckOptions:
- key: cert-dcl16-c.NewSuffixes
value: 'L;LL;LU;LLU'
- key: cert-oop54-cpp.WarnOnlyIfThisHasSuspiciousField
value: '0'
- key: cppcoreguidelines-explicit-virtual-functions.IgnoreDestructors
value: '1'
- key: cppcoreguidelines-non-private-member-variables-in-classes.IgnoreClassesWithAllMemberVariablesBeingPublic
value: '1'
- key: cppcoreguidelines-pro-type-member-init.IgnoreArrays
value: '1'
- key: cppcoreguidelines-pro-type-member-init.UseAssignment
value: '1'
- key: google-readability-function-size.StatementThreshold
value: '800'
- key: google-readability-namespace-comments.ShortNamespaceLines
value: '10'
- key: google-readability-namespace-comments.SpacesBeforeComments
value: '2'
- key: modernize-loop-convert.MaxCopySize
value: '16'
- key: modernize-loop-convert.MinConfidence
value: reasonable
- key: modernize-loop-convert.NamingStyle
value: CamelCase
- key: modernize-pass-by-value.IncludeStyle
value: llvm
- key: modernize-replace-auto-ptr.IncludeStyle
value: llvm
- key: modernize-use-bool-literals.IgnoreMacros
value: '0'
- key: modernize-use-default-member-init.IgnoreMacros
value: '0'
- key: modernize-use-default-member-init.UseAssignment
value: '1'
- key: modernize-use-nullptr.NullMacros
value: 'NULL'
- key: readability-braces-around-statements.ShortStatementLines
value: '0'
...

Loading