Spaces:
Running
on
Zero
Running
on
Zero
File size: 2,509 Bytes
344c16f |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# Pixi is a package management tool for developers.
# Before running a task, pixi ensures that all listed dependencies are installed first.echop
#
# Pixi is not required for rerun, but it is a convenient way to install the
# dependencies required for this example.
#
# https://prefix.dev/docs/pixi/overview
#
# Use `pixi task list` to list the available tasks,
# and `pixi run TASK` to run it (e.g. `pixi run example`).
[project]
name = "new_project_name"
authors = ["rerun.io <opensource@rerun.io>"]
channels = ["conda-forge"]
description = "new_project_name"
homepage = "https://rerun.io"
license = "MIT OR Apache-2.0"
platforms = ["linux-64", "linux-aarch64", "osx-arm64", "osx-64", "win-64"]
readme = "README.md"
repository = "https://github.com/rerun-io/new_repo_name"
version = "0.1.0"
[tasks]
# ------------------------------------------------------------------------------------------
# C++ stuff:
# Note: extra CLI argument after `pixi run TASK` are passed to the task cmd.
# Clean C++ build artifacts
clean = { cmd = "rm -rf build bin CMakeFiles/" }
print-env = { cmd = "echo $PATH" }
prepare = "cmake -G 'Ninja' -B build -S . -DCMAKE_BUILD_TYPE=RelWithDebInfo"
# Build C++ example
build = { cmd = "cmake --build build --config RelWithDebInfo --target all", depends_on = [
"prepare",
] }
# Run C++ example
example = { cmd = "build/PROJ_NAME", depends_on = ["build"] }
# Format C++ code
cpp-fmt = { cmd = "clang-format -i src/*.[hc]pp" }
# Check formatting of C++ code
cpp-fmt-check = { cmd = "clang-format --dry-run --Werror -i src/*.[hc]pp" }
# ------------------------------------------------------------------------------------------
# Python stuff:
# Run first ruff fix, then ruff format, order is important see also https://twitter.com/charliermarsh/status/1717229721954799727
py-fmt = "ruff check --fix --config pyproject.toml . && ruff format --config pyproject.toml ."
py-fmt-check = "ruff check --config pyproject.toml . && ruff format --check --config pyproject.toml"
py-lint = "mypy --install-types --non-interactive --no-warn-unused-ignore"
# ------------------------------------------------------------------------------------------
# General stuff:
lint-typos = "typos"
[dependencies]
# C++ build-tools:
cmake = "3.27.6"
clang-tools = ">=15,<16" # clang-format
cxx-compiler = "1.6.0.*"
ninja = "1.11.1"
# Python stuff:
mypy = "1.8.0"
ruff = "0.3.7"
types-requests = ">=2.31,<3" # mypy type hint stubs for generate_changelog.py
# General stuff:
typos = ">=1.16.20"
|