Skip to content

Commit 7066d56

Browse files
authored
Merge pull request #20 from LiteLDev/develop
Release
2 parents 35f3cd0 + 3f5d08a commit 7066d56

File tree

410 files changed

+59084
-33259
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

410 files changed

+59084
-33259
lines changed

.clang-format

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
BasedOnStyle: LLVM
2+
AccessModifierOffset: -4
3+
AlignAfterOpenBracket: BlockIndent
4+
AlignArrayOfStructures: Left
5+
AlignConsecutiveDeclarations:
6+
Enabled: true
7+
AcrossEmptyLines: false
8+
AcrossComments: false
9+
AlignConsecutiveAssignments:
10+
Enabled: true
11+
AcrossEmptyLines: false
12+
AcrossComments: false
13+
AlignCompound: true
14+
PadOperators: true
15+
AlignConsecutiveMacros:
16+
Enabled: true
17+
AcrossEmptyLines: false
18+
AcrossComments: false
19+
AllowAllParametersOfDeclarationOnNextLine: false
20+
AllowAllArgumentsOnNextLine: false
21+
AlignOperands: AlignAfterOperator
22+
AlignConsecutiveBitFields:
23+
Enabled: true
24+
AcrossEmptyLines: false
25+
AcrossComments: false
26+
AllowShortLambdasOnASingleLine: All
27+
AllowShortBlocksOnASingleLine: Empty
28+
AllowShortIfStatementsOnASingleLine: AllIfsAndElse
29+
AllowShortLoopsOnASingleLine: true
30+
AlwaysBreakAfterDefinitionReturnType: None
31+
AlwaysBreakTemplateDeclarations: 'Yes'
32+
BinPackArguments: false
33+
BinPackParameters: false
34+
BreakBeforeBraces: Custom
35+
BreakBeforeBinaryOperators: NonAssignment
36+
ColumnLimit: 120
37+
CommentPragmas: '^ IWYU pragma:'
38+
ConstructorInitializerIndentWidth: 0
39+
IndentWidth: 4
40+
Language: Cpp
41+
MaxEmptyLinesToKeep: 1
42+
PackConstructorInitializers: CurrentLine
43+
PointerAlignment: Left
44+
TabWidth: 4
45+
UseTab: Never
46+
SortIncludes: CaseSensitive
47+
IncludeBlocks: Regroup

.clang-tidy

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
Checks: '
3+
bugprone-*,
4+
clang-analyzer-*,
5+
concurrency-*,
6+
cppcoreguidelines-*,
7+
llvm-*,
8+
misc-*,
9+
modernize-*,
10+
performance-*,
11+
portability-*,
12+
readability-*
13+
'
14+
...

.clangd

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
Diagnostics:
2-
Suppress:
2+
Suppress:
33
- "-Wmicrosoft-enum-forward-reference"
44
- "-Wc++11-narrowing"
55
- "-Wc++2b-extensions"
66
- "-Wmicrosoft-cast"
77
CompileFlags:
8-
Add:
8+
Add:
99
- "-ferror-limit=0"
10-
- "-D__FUNCTION__=\"dummy\""
10+
- '-D__FUNCTION__="dummy"'

.gitattributes

Lines changed: 88 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,90 @@
1-
## C++
1+
## https://github.com/gitattributes/gitattributes/blob/master/Common.gitattributes
2+
# Common settings that generally should always be used with your language specific settings
3+
4+
# Auto detect text files and perform LF normalization
5+
* text=auto
6+
7+
#
8+
# The above will handle all files NOT found below
9+
#
10+
11+
# Documents
12+
*.bibtex text diff=bibtex
13+
*.doc diff=astextplain
14+
*.DOC diff=astextplain
15+
*.docx diff=astextplain
16+
*.DOCX diff=astextplain
17+
*.dot diff=astextplain
18+
*.DOT diff=astextplain
19+
*.pdf diff=astextplain
20+
*.PDF diff=astextplain
21+
*.rtf diff=astextplain
22+
*.RTF diff=astextplain
23+
*.md text diff=markdown
24+
*.mdx text diff=markdown
25+
*.tex text diff=tex
26+
*.adoc text
27+
*.textile text
28+
*.mustache text
29+
*.csv text eol=crlf
30+
*.tab text
31+
*.tsv text
32+
*.txt text
33+
*.sql text
34+
*.epub diff=astextplain
35+
36+
# Graphics
37+
*.png binary
38+
*.jpg binary
39+
*.jpeg binary
40+
*.gif binary
41+
*.tif binary
42+
*.tiff binary
43+
*.ico binary
44+
# SVG treated as text by default.
45+
*.svg text
46+
# If you want to treat it as binary,
47+
# use the following line instead.
48+
# *.svg binary
49+
*.eps binary
50+
51+
# Scripts
52+
*.bash text eol=lf
53+
*.fish text eol=lf
54+
*.sh text eol=lf
55+
*.zsh text eol=lf
56+
# These are explicitly windows files and should use crlf
57+
*.bat text eol=crlf
58+
*.cmd text eol=crlf
59+
*.ps1 text eol=crlf
60+
61+
# Serialisation
62+
*.json text
63+
*.toml text
64+
*.xml text
65+
*.yaml text
66+
*.yml text
67+
68+
# Archives
69+
*.7z binary
70+
*.gz binary
71+
*.tar binary
72+
*.tgz binary
73+
*.zip binary
74+
75+
# Text files where line endings should be preserved
76+
*.patch -text
77+
78+
#
79+
# Exclude files from exporting
80+
#
81+
82+
.gitattributes export-ignore
83+
.gitignore export-ignore
84+
.gitkeep export-ignore
85+
86+
87+
## https://github.com/gitattributes/gitattributes/blob/master/C%2B%2B.gitattributes
288
# Sources
389
*.c text diff=cpp
490
*.cc text diff=cpp
@@ -38,4 +124,4 @@
38124
*.app binary
39125

40126

41-
## Others
127+
## Project specific

.github/workflows/build.yml

Lines changed: 20 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,26 @@ on:
55

66
jobs:
77
build:
8+
runs-on: windows-latest
89
strategy:
910
matrix:
1011
backend:
12+
# - libnode
1113
- lua
12-
- nodejs
13-
- python310
14+
# - python310
1415
- quickjs
15-
runs-on: windows-latest
1616
steps:
1717
- uses: actions/checkout@v4
1818

1919
- uses: xmake-io/github-action-setup-xmake@v1
20+
21+
- uses: actions/cache@v4
22+
with:
23+
path: |
24+
~/AppData/Local/.xmake
25+
key: xmake-${{ hashFiles('xmake.lua') }}
26+
restore-keys: |
27+
xmake-
2028
2129
- run: |
2230
xmake repo -u
@@ -27,24 +35,21 @@ jobs:
2735
- run: |
2836
xmake -w -y
2937
30-
- uses: actions/upload-artifact@v3
38+
- uses: actions/upload-artifact@v4
3139
with:
3240
name: legacy-script-engine-${{ matrix.backend }}-windows-x64-${{ github.sha }}
3341
path: |
34-
build/windows/x64/release/legacy-script-engine-${{ matrix.backend }}.dll
35-
build/windows/x64/release/legacy-script-engine-${{ matrix.backend }}.pdb
42+
bin/
3643
37-
check-style:
38-
runs-on: ubuntu-latest
44+
clang-format:
45+
runs-on: windows-latest
3946
steps:
4047
- uses: actions/checkout@v4
4148

42-
- uses: actions/setup-node@v3
43-
with:
44-
node-version: 18
45-
4649
- run: |
47-
npm install clang-format@1.8.0
50+
choco install llvm -y --version=17.0.6
4851
49-
- run: |
50-
npx clang-format --dry-run --Werror $(find . -type f -name '*.cpp' -o -name '*.h')
52+
- name: clang-format
53+
run: |
54+
Get-ChildItem src/ -Filter *.cpp -Recurse | ForEach-Object { clang-format -i -Werror $_.FullName }
55+
Get-ChildItem src/ -Filter *.h -Recurse | ForEach-Object { clang-format -i -Werror $_.FullName }

.github/workflows/build_docs.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
on:
2+
push:
3+
paths:
4+
- .github/workflows/build_docs.yml
5+
- docs/**
6+
- mkdocs.yml
7+
workflow_dispatch:
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
15+
- run: |
16+
pip install -r requirements.txt
17+
18+
- run: |
19+
mkdocs build
20+
21+
- uses: actions/upload-pages-artifact@v3
22+
with:
23+
path: site/
24+
25+
deploy:
26+
if: github.ref == 'refs/heads/main' && github.event_name == 'push'
27+
needs:
28+
- build
29+
permissions:
30+
id-token: write
31+
pages: write
32+
runs-on: ubuntu-latest
33+
steps:
34+
- uses: actions/deploy-pages@v4
35+

0 commit comments

Comments
 (0)