Skip to content

Commit ca7c3a5

Browse files
authored
Feature/add fix option (#30)
* added '--fix' option * updated to rust 1.76 * removed BranchThreshold * debugging windows test failure * running windows tests * switching to llvm only * switching to llvm only * added -fix-errors * re-enabling the full CI
1 parent aaa4289 commit ca7c3a5

File tree

17 files changed

+340
-274
lines changed

17 files changed

+340
-274
lines changed

.github/setup/load_artifacts_macos.sh

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/sh
22

3-
brew install gcc wget make python3
3+
brew install wget make python3
44

55
pip3 install \
66
argparse \
@@ -11,13 +11,22 @@ pkg="clang+llvm-$ver-x86_64-apple-darwin"
1111

1212
wget -O clang-$ver.tgz "https://github.com/llvm/llvm-project/releases/download/llvmorg-$ver/$pkg.tar.xz"
1313
mkdir -p artifacts/clang
14-
tar -xf clang-$ver.tgz $pkg/bin/clang-tidy
15-
mv $pkg/bin/clang-tidy artifacts/clang
14+
15+
# extract all binaries
16+
tar -xf clang-$ver.tgz $pkg/bin
17+
18+
# move the binaries to the artifacts folder
19+
mv $pkg/bin/* artifacts/clang
20+
1621
rm -rf $pkg
1722
rm clang-$ver.tgz
1823

1924
ls -la artifacts/clang
2025
artifacts/clang/clang-tidy --version
2126

27+
# generate compile-commands.json
2228
gmake -C test-files/c-demo/project build-data
23-
ls -la test-files/c-demo/_bld/out
29+
ls -la test-files/c-demo/_bld/out
30+
31+
# build project (clang-tidy can fail due to compiler errors)
32+
gmake -C test-files/c-demo/project

.github/setup/load_artifacts_ubuntu.sh

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ fi
1010
sudo apt-get update
1111
sudo apt-get install -y --no-install-recommends \
1212
wget \
13-
gcc \
1413
make \
1514
python3 \
1615
python3-pip \
@@ -38,13 +37,22 @@ pkg="clang+llvm-$ver-x86_64-linux-gnu-ubuntu-18.04"
3837

3938
wget -O clang-$ver.tgz "https://github.com/llvm/llvm-project/releases/download/llvmorg-$ver/$pkg.tar.xz"
4039
mkdir -p artifacts/clang
41-
tar -xf clang-$ver.tgz $pkg/bin/clang-tidy
42-
mv $pkg/bin/clang-tidy artifacts/clang
40+
41+
# extract all binaries
42+
tar -xf clang-$ver.tgz $pkg/bin
43+
44+
# move the binaries to the artifacts folder
45+
mv $pkg/bin/* artifacts/clang
46+
4347
rm -rf $pkg
4448
rm clang-$ver.tgz
4549

4650
ls -la artifacts/clang
4751
artifacts/clang/clang-tidy --version
4852

53+
# generate compile-commands.json
4954
make -C test-files/c-demo/project build-data
50-
ls -la test-files/c-demo/_bld/out
55+
ls -la test-files/c-demo/_bld/out
56+
57+
# build project (clang-tidy can fail due to compiler errors)
58+
make -C test-files/c-demo/project
Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11

22
@REM powershell -Command "Invoke-WebRequest https://github.com/llvm/llvm-project/releases/download/llvmorg-14.0.0/LLVM-14.0.0-win64.exe -OutFile llvm.exe"
3+
@REM choco install python3 -y
4+
@REM choco install choco install mingw -y
35

4-
choco install python3 -y
5-
choco install choco install mingw -y
66
choco install make
77

88
pip3 install argparse datetime
@@ -12,8 +12,9 @@ dir "%SYSTEMDRIVE%\Program Files\LLVM\bin"
1212

1313
mkdir "artifacts\clang"
1414
copy "%SYSTEMDRIVE%\Program Files\LLVM\bin\clang-tidy.exe" "artifacts\clang"
15-
16-
@REM artifacts\clang\clang-tidy.exe --version
15+
copy "%SYSTEMDRIVE%\Program Files\LLVM\bin\clang.exe" "artifacts\clang"
1716

1817
make -C test-files\c-demo\project build-data
19-
dir test-files\c-demo\_bld\out
18+
dir test-files\c-demo\_bld\out
19+
20+
make -C test-files\c-demo\project

.github/workflows/ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ jobs:
5858
# alternatively matrix could be shared and specified via .json
5959
# see https://github.community/t/how-to-share-matrix-between-jobs/128595/8
6060
# ---
61-
- { build: 'linux-x86_64-pinned', os: 'ubuntu-22.04', target: 'x86_64-unknown-linux-gnu', cross: false, rust: 1.74.0, archive: true }
62-
- { build: 'windows-x86_64-pinned', os: 'windows-2019', target: 'x86_64-pc-windows-msvc', cross: false, rust: 1.74.0, archive: true }
63-
- { build: 'macos-x86_64-pinned', os: 'macos-latest', target: 'x86_64-apple-darwin', cross: false, rust: 1.74.0, archive: true }
61+
- { build: 'linux-x86_64-pinned', os: 'ubuntu-22.04', target: 'x86_64-unknown-linux-gnu', cross: false, rust: 1.76.0, archive: true }
62+
- { build: 'windows-x86_64-pinned', os: 'windows-2019', target: 'x86_64-pc-windows-msvc', cross: false, rust: 1.76.0, archive: true }
63+
- { build: 'macos-x86_64-pinned', os: 'macos-latest', target: 'x86_64-apple-darwin', cross: false, rust: 1.76.0, archive: true }
6464
- { build: 'linux-x86_64', os: 'ubuntu-latest', target: 'x86_64-unknown-linux-gnu', cross: false, rust: stable, archive: false }
6565
- { build: 'linux-i686', os: 'ubuntu-latest', target: 'i686-unknown-linux-gnu', cross: true, rust: stable, archive: false }
6666
- { build: 'linux-arm', os: 'ubuntu-latest', target: 'aarch64-unknown-linux-gnu', cross: true, rust: stable, archive: false } # aarch64

0 commit comments

Comments
 (0)