Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 2 additions & 0 deletions .qlty/hooks/pre-commit.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#\!/bin/sh
qlty fmt --trigger pre-commit --index-file="$GIT_INDEX_FILE"
6 changes: 6 additions & 0 deletions .qlty/hooks/pre-push.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#\!/bin/sh
qlty check \
--trigger pre-push \
--upstream-from-pre-push \
--no-formatters \
--skip-errored-plugins
39 changes: 39 additions & 0 deletions .qlty/qlty.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
config_version = "0"

exclude_patterns = [
"build/**",
"target/**",
"src/libshared/**",
"src/taskchampion-cpp/corrosion/**",
]

test_patterns = [
"test/**",
]

[smells]
mode = "comment"

[[source]]
name = "default"
default = true

# Rust linting via clippy
[[plugin]]
name = "clippy"
mode = "block"

# Rust formatting via rustfmt
[[plugin]]
name = "rustfmt"
mode = "block"

# Secret scanning — catches leaked API keys, credentials
[[plugin]]
name = "trufflehog"
mode = "block"

# Dependency vulnerability scanning (scans Cargo.lock)
[[plugin]]
name = "osv-scanner"
mode = "block"
36 changes: 36 additions & 0 deletions .woodpecker/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
clone:
git:
image: woodpeckerci/plugin-git
settings:
recursive: true

when:
- event: pull_request
- event: push
branch: develop

steps:
- name: rust-fmt
image: rust:1.88
commands:
- rustup component add rustfmt
- cargo fmt --all -- --check

- name: clippy
image: rust:1.88
commands:
- rustup component add clippy
- cargo clippy --all-features -- -D warnings

- name: cargo-test
image: rust:1.88
commands:
- cargo test

- name: cmake-build-test
image: rust:1.88
commands:
- apt-get update && apt-get install -y --no-install-recommends
build-essential cmake git uuid-dev faketime locales
python3 ninja-build ca-certificates make
- make test
24 changes: 24 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
BUILD_DIR := build
BUILD_DIR_TEST := build-test
BUILD_TYPE ?= Release
NPROC := $(shell nproc 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null || echo 4)

.PHONY: build install test clean

build:
cmake -S . -B $(BUILD_DIR) -DCMAKE_BUILD_TYPE=$(BUILD_TYPE)
cmake --build $(BUILD_DIR) -j$(NPROC)

# Installs task binary, man pages, and docs per CMakeLists.txt install() rules.
# Use CMAKE_INSTALL_PREFIX to control destination (default: /usr/local).
install: build
cmake --install $(BUILD_DIR)

# Uses a separate build-test dir (Debug) so it never clobbers the release build.
test:
cmake -S . -B $(BUILD_DIR_TEST) -DCMAKE_BUILD_TYPE=Debug
cmake --build $(BUILD_DIR_TEST) --target test_runner --target task_executable -j$(NPROC)
ctest --test-dir $(BUILD_DIR_TEST) -j$(NPROC) --output-on-failure

clean:
rm -rf $(BUILD_DIR) $(BUILD_DIR_TEST)
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<div align="center">
<img src="https://avatars.githubusercontent.com/u/36100920?s=200&u=24da05914c20c4ccfe8485310f7b83049407fa9a&v=4"></br>

[![CI](https://ci.guion.io/api/badges/GuionAI/taskwarrior/status.svg)](https://ci.guion.io/GuionAI/taskwarrior)
[![GitHub Actions build status](https://github.com/GothenburgBitFactory/taskwarrior/workflows/tests/badge.svg?branch=develop)](https://github.com/GothenburgBitFactory/taskwarrior/actions)
[![Coverage Status](https://coveralls.io/repos/github/GothenburgBitFactory/taskwarrior/badge.svg?branch=develop)](https://coveralls.io/github/GothenburgBitFactory/taskwarrior?branch=develop)
[![Release](https://img.shields.io/github/v/release/GothenburgBitFactory/taskwarrior)](https://github.com/GothenburgBitFactory/taskwarrior/releases/latest)
Expand Down
Loading