feat: readme and doxyfile

This commit is contained in:
2025-08-23 13:17:52 +02:00
parent 24ebb67fb5
commit ed775a2da0
2 changed files with 92 additions and 5 deletions

View File

@@ -1,5 +1,58 @@
OUTPUT_DIRECTORY = docs
GENERATE_HTML = YES
GENERATE_LATEX = NO
INPUT *.c *.h
# Project identity
PROJECT_NAME = "tstd"
PROJECT_NUMBER = 0.1.0
PROJECT_BRIEF = "Tiny STD-like utilities in C"
OUTPUT_DIRECTORY = docs
# Input
INPUT = src include README.md
FILE_PATTERNS = *.c *.h *.md
RECURSIVE = YES
EXCLUDE = build docs
EXCLUDE_PATTERNS = */.git/* */.cache/*
# Main page
USE_MDFILE_AS_MAINPAGE = README.md
MARKDOWN_SUPPORT = YES
EXTENSION_MAPPING = md=markdown
# HTML
GENERATE_HTML = YES
HTML_OUTPUT = html
GENERATE_TREEVIEW = YES
HTML_DYNAMIC_SECTIONS = YES
SEARCHENGINE = YES
# LaTeX/PDF
GENERATE_LATEX = NO
# Source browsing
SOURCE_BROWSER = YES
INLINE_SOURCES = YES
STRIP_CODE_COMMENTS = NO
# Extraction and docs quality
EXTRACT_ALL = YES
EXTRACT_PRIVATE = NO
EXTRACT_STATIC = YES
EXTRACT_LOCAL_CLASSES = YES
HAVE_DOT = YES
CALL_GRAPH = YES
CALLER_GRAPH = YES
DOT_IMAGE_FORMAT = svg
INTERACTIVE_SVG = YES
DOT_TRANSPARENT = YES
# Warnings and tidy
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_NO_PARAMDOC = YES
WARN_AS_ERROR = NO
QUIET = NO
# Preprocessor
ENABLE_PREPROCESSING = YES
MACRO_EXPANSION = YES
EXPAND_ONLY_PREDEF = NO
INCLUDE_PATH = include

34
README.md Normal file
View File

@@ -0,0 +1,34 @@
# TSTD
A C library providing various string manipulation utilities.
## Usage
To use TSTD in your CMake project, you can either build it from source or include it using FetchContent.
### Integration with FetchContent
Add the following to your CMakeLists.txt:
```cmake
cmake_minimum_required(VERSION 3.20)
project(myproj C)
set(CMAKE_C_STANDARD 23)
set(CMAKE_C_STANDARD_REQUIRED ON)
include(FetchContent)
FetchContent_Declare(
tstd
GIT_REPOSITORY https://github.com/Tilo-K/tstd.git
GIT_TAG main
)
FetchContent_MakeAvailable(tstd)
add_executable(myapp src/main.c)
target_link_libraries(myapp PRIVATE tstd)
```