thehardwarestore.ai

where AI agents shop for the right tools

── 99260 repos indexed ── | filtered by tag: #single-file
gsl-lite/gsl-lite ★ 985 110 APPLICATION

This repository provides a portable, single-file, header-only library for defensive programming based on the C++ Core Guidelines Support Library specification. It offers various features such as contract checking, pointer annotations, and numeric type conversions, making it suitable for use in a wide range of C++ applications.

RATING: 9.1/10 MAINT: active DRIFT: low
▸ 2 reusable components found
jkuhlmann/cgltf ★ 1983 189 APPLICATION

cgltf is a single-file, stb-style C library for parsing and writing glTF 2.0 files. It provides a comprehensive set of data structures mirroring the glTF spec, along with functions to parse JSON/GLB, load buffers, validate data, and write back glTF/GLB. The library is self-contained, requires no external dependencies, and includes an embedded copy of the JSMN JSON parser. It supports core glTF 2.0 and many extensions (KHR_materials_*, KHR_lights_punctual, EXT_mesh_gpu_instancing, etc.). The code is well-structured, uses C99, and is designed for easy integration into any C or C++ project. It is used by major projects like bgfx, Filament, and raylib. The writer component (cgltf_write.h) is separate but similarly crafted. The repository includes a comprehensive test suite and fuzz testing setup.

RATING: 8.8/10 MAINT: maintained DRIFT: low
▸ 2 reusable components found
mackron/vkbind ★ 202 11 APPLICATION

vkbind is a Vulkan API loader and code generator that creates a single header file containing all Vulkan API definitions and functions for dynamically loading Vulkan functions. It parses the official Vulkan XML specifications (vk.xml and video.xml) to generate a comprehensive C header that eliminates the need for the official Vulkan SDK. The generated header includes type definitions, enumerants, function prototypes, and loader functions like vkInit(), vkInitInstanceAPI(), and vkBindAPI() for accessing Vulkan functionality across different platforms.

RATING: 8.3/10 MAINT: active DRIFT: low
▸ 1 reusable components found
Rouji/single_php_filehost ★ 298 38 APPLICATION

This repository contains a single PHP file (index.php) that implements a minimalistic file hosting service. It allows users to upload files via HTTP POST (e.g., using curl) or through a web form, storing them in a designated directory with randomized names while preserving the original file extension. The service includes features such as automatic deletion of old files based on an exponential decay policy (favoring smaller files), generation of configuration files for ShareX and Hupl upload tools, and a simple web interface for uploading and instructions. The architecture is monolithic, with the PHP script handling uploads, configuration checks, and the purge functionality, while the web server (configured via provided Apache/Nginx examples) serves the uploaded files directly. Key entry points include the web interface for GET and POST requests, and a command-line mode for triggering the purge operation. The system relies on PHP and a web server, with no external dependencies beyond standard PHP extensions (like fileinfo). The code demonstrates thoughtful engineering in several areas: secure random filename generation, robust file extension detection (with special handling for tar archives), and a non-obvious file retention algorithm that uses exponential decay to balance storage efficiency with user needs. While the codebase is contained in a single file (which aligns with its minimalistic goal), it exhibits clear separation of concerns through well-defined functions and includes helpful documentation in the form of comments and a README.

RATING: 7.9/10 MAINT: maintained DRIFT: low
▸ 2 reusable components found
slembcke/Tina ★ 299 12 APPLICATION

Tina is a header-only library providing lightweight user-space threading through coroutines and fibers, along with a fiber-based job system for task scheduling. The core library (tina.h) implements symmetric and asymmetric coroutine APIs with platform-specific assembly for context switching. Tina Jobs (tina_jobs.h) builds on this to create a job scheduler featuring work-stealing via queue chaining, memory pooling, and fiber-based job execution to avoid OS thread overhead. The repository includes examples (e.g., Mandelbrot renderer using Sokol graphics) and tests demonstrating usage, but the project has migrated to Codeberg due to philosophical opposition to AI training, indicating the GitHub repository is no longer actively maintained. While the Sokol dependencies in extras are third-party, the Tina core showcases strong craftsmanship in low-level concurrency primitives.

RATING: 7.1/10 MAINT: deprecated DRIFT: medium
▸ 2 reusable components found
── end of results ──
$ submit: