Skip to content

TsukiNi22/ai-utils / skills/cpp/cpp-class

cpp-class

Unverified

Generate C++ (C++20) .hpp/.cpp files and class architectures in Tsukini's style (Xartania header, indented include guards, INCLUDE/CLASS sections, Pre-Function/Function/Operator/Constructor/Destructor blocks, libutils attributes or standard [[...]]), with empty bodies only (never the logic), then register the .cpp in the CMakeLists.txt. Also creates the main.cpp entry point in the same style. Use whenever the user asks to create, scaffold or add a C++ class, a main / entry point, interface (I*), abstract class (A*), template, struct/Type or Define header, module or set of .hpp/.cpp files.

examples/ArgParserType.hpp

View on GitHub
/**************************************************************\

 ██╗  ██╗ █████╗ ██████╗ ████████╗ █████╗ ███╗   ██╗██╗ █████╗
 ╚██╗██╔╝██╔══██╗██╔══██╗╚══██╔══╝██╔══██╗████╗  ██║██║██╔══██╗
  ╚███╔╝ ███████║██████╔╝   ██║   ███████║██╔██╗ ██║██║███████║
  ██╔██╗ ██╔══██║██╔══██╗   ██║   ██╔══██║██║╚██╗██║██║██╔══██║
 ██╔╝ ██╗██║  ██║██║  ██║   ██║   ██║  ██║██║ ╚████║██║██║  ██║
 ╚═╝  ╚═╝╚═╝  ╚═╝╚═╝  ╚═╝   ╚═╝   ╚═╝  ╚═╝╚═╝  ╚═══╝╚═╝╚═╝  ╚═╝

Edition:
##  @date 21/09/2026 by @author Tsukini

File Name:
##  @file ArgParserType.hpp

File Description:
##  Declaration of the ArgParser type for void & non void function
\**************************************************************/

#ifndef ARGPARSERTYPE_H
    #define ARGPARSERTYPE_H

    //----------------------------------------------------------------//
    /* INCLUDE */

    /* type */
    #include <functional>   // std::function
    #include <optional>     // std::optional
    #include <utility>      // std::pair
    #include <vector>       // std::vector
    #include <string>       // std::string
    #include <deque>        // std::deque
    #include <tuple>        // std::tuple

namespace utils::arguments { // namespace start
//----------------------------------------------------------------//
/* STRUCT */

// Return of the parser
/* internaly used */
struct ParsedUsageFull {
    std::string id; // empty -> nothing
    bool valid = true; // keep the usage for the final return
    bool ordered = false; // is the usage ordered
    std::deque<std::pair<std::string, bool>> ids; // ids that are still not used in the arguments
    std::vector<std::tuple<std::string, bool, std::vector<std::string>>> arguments; // <id, option(true)|flag(false), {option}>
};

/* user return */
struct ParsedUsage {
    std::string id; // empty -> nothing
    std::vector<std::tuple<std::string, bool, std::vector<std::string>>> arguments; // <id, option(true)|flag(false), {option}>
};

struct Usage {
    std::string name; // special name: default -> allow all flag (like no usage defined)
    bool ordered = false; // The order of the option will always matter, Raw option will be forced in mandatory
    std::vector<std::pair<std::string, bool>> ids; // List of ids allowed by this usage <id, mandatory>
    std::string description = "[None]";
};

struct Option {
    std::string name;
    bool exact = false;
    std::function<std::optional<std::string>(const std::string&)> check;
    std::string description = "[None]";
};

struct Flag {
    std::tuple<std::string, std::string, std::string, std::string> flag; // <short, flag, long, env>
    std::pair<bool, bool> unlimited = {false, false}; // <ulimited, ignore flag>
    std::vector<std::tuple<std::string, bool, std::function<std::optional<std::string>(const std::string&)>>> options; // <name, mandatory, check>, the order matter
    std::string description = "[None]";
};

//----------------------------------------------------------------//
/* TYPEDEF */

using ParsedUsages = std::vector<utils::arguments::ParsedUsage>;

} // namespace end
#endif /* ARGPARSERTYPE_H */
slack-gif-creatoranthropics/skillsKnowledge and utilities for creating animated GIFs optimized for Slack. Provides constraints, validation tools, and animation concepts. Use when users request animated GIFs for Slack like "make me a GIF of X doing Y for Slack."Stars: 196kUpdated Claude CodeCodexVerifiedInstall
ponytailDietrichGebert/ponytailLazy senior dev mode for any coding task: the smallest change that fully solves it, and a reply a busy human understands in one read.Stars: 192kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailHarvest every shortcut: comment into one debt ledger, so deferrals get tracked instead of forgotten. One-shot report.Stars: 192kUpdated Claude CodeCodexVerifiedInstall
ponytail-debtDietrichGebert/ponytailList every `shortcut:` comment (and older `ponytail:` ones) as a debt ledger. One-shot report, changes nothing. Use for "ponytail debt", "what did ponytail defer", "list the shortcuts", /ponytail-debt.Stars: 192kUpdated Claude CodeCodexVerifiedInstall