Files
clice/pixi.toml
2025-12-17 13:04:02 +08:00

118 lines
2.7 KiB
TOML

[workspace]
name = "clice"
version = "0.1.0"
description = "A next-generation C++ language server for modern C++"
authors = [
"ykiko <ykikoykikoykiko@gmail.com>",
"clice contributors <clice@clice.io>",
]
license = "Apache-2.0"
license-file = "LICENSE"
readme = "README.md"
documentation = "https://clice.io"
repository = "https://github.com/clice-io/clice"
channels = ["conda-forge"]
platforms = ["win-64", "linux-64", "osx-arm64"]
[dependencies]
python = ">=3.13"
cmake = ">=3.30"
ninja = "*"
clang = "==20.1.8"
clangxx = "==20.1.8"
lld = "==20.1.8"
llvm-tools = "==20.1.8"
compiler-rt = "==20.1.8"
[target.linux-64.dependencies]
sysroot_linux-64 = "==2.17"
gcc = "==14.2.0"
gxx = "==14.2.0"
[target.win-64.activation]
scripts = ["scripts/activate_asan.bat"]
[target.linux-64.activation]
scripts = ["scripts/activate_linux.sh"]
[feature.test.pypi-dependencies]
pytest = "*"
pytest-asyncio = ">=1.1.0"
pre-commit = ">=4.3.0"
[feature.package.dependencies]
xz = ">=5.8.1,<6"
[environments]
default = []
develop = ["test", "develop"]
package = ["test", "package"]
[tasks.ci-cmake-configure]
args = ["build_type"]
cmd = ["cmake", "-B", "build", "-G", "Ninja",
"-DCMAKE_BUILD_TYPE={{ build_type }}",
"-DCMAKE_TOOLCHAIN_FILE=cmake/toolchain.cmake",
"-DCLICE_ENABLE_TEST=ON",
"-DCLICE_CI_ENVIRONMENT=ON",
]
[tasks.cmake-build]
cmd = "cmake --build build"
[feature.develop.tasks]
unit-test = './build/bin/unit_tests --test-dir="./tests/data"'
integration-test = 'pytest -s --log-cli-level=INFO tests/integration --executable=./build/bin/clice{% if pixi.is_win %}.exe{% endif %}'
ci-check = "pre-commit run --all-files"
xmake-test = "xmake test --verbose"
[tasks.ci-cmake-build]
args = ["build_type"]
depends-on = [
{ task = "ci-cmake-configure", args = ["{{ build_type }}"] },
{ task = "cmake-build" },
]
[tasks.ci-cmake-test]
depends-on = [
{ task = "unit-test" },
{ task = "integration-test" },
]
[tasks.ci-xmake-configure]
args = ["build_type"]
cmd = "xmake config --clean --yes --mode={{ build_type }} --toolchain=clang --ci=y"
[tasks.xmake-build]
cmd = "xmake build --verbose --diagnosis --all"
[tasks.ci-xmake-build]
args = ["build_type"]
depends-on = [
{ task = "ci-xmake-configure", args = ["{{ build_type }}"] },
{ task = "xmake-build" },
]
[tasks.build-llvm]
cmd = ["python3", "scripts/build-llvm.py"]
[tasks.upload-llvm]
args = [
"workflow_id",
"llvm_version",
{ "arg" = "branch", default = "main" },
]
cmd = [
"gh", "workflow", "run", "upload-llvm.yml",
"--ref", "{{ branch }}",
"--field", "workflow_id={{workflow_id}}",
"--field", "version={{llvm_version}}",
]
[tasks.delete-artifacts]
# delete all workflows generated by "file_name"
args = ["file_name"]
cmd = ["scripts/delete-artifacts.bash", "{{ file_name }}"]