{"id":13731115,"url":"https://github.com/flipcoder/kit","last_synced_at":"2025-05-08T03:32:54.719Z","repository":{"id":12621929,"uuid":"15293153","full_name":"flipcoder/kit","owner":"flipcoder","description":"C++11 libs: await, channels, reactive/signals, timelines, alarms, logging, args, etc.","archived":false,"fork":false,"pushed_at":"2020-12-29T19:19:19.000Z","size":362,"stargazers_count":23,"open_issues_count":1,"forks_count":9,"subscribers_count":7,"default_branch":"master","last_synced_at":"2024-11-14T21:38:23.724Z","etag":null,"topics":["animation","async","coroutines","cpp","cpp11","json","reactive","threads","timers"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/flipcoder.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-12-18T20:12:29.000Z","updated_at":"2023-07-11T11:30:02.000Z","dependencies_parsed_at":"2022-09-19T07:40:30.966Z","dependency_job_id":null,"html_url":"https://github.com/flipcoder/kit","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flipcoder%2Fkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flipcoder%2Fkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flipcoder%2Fkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/flipcoder%2Fkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/flipcoder","download_url":"https://codeload.github.com/flipcoder/kit/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252994467,"owners_count":21837423,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["animation","async","coroutines","cpp","cpp11","json","reactive","threads","timers"],"created_at":"2024-08-03T02:01:24.066Z","updated_at":"2025-05-08T03:32:54.410Z","avatar_url":"https://github.com/flipcoder.png","language":"C++","readme":"# kit\nReally cool C++ stuff, including modern async\n\nOpen-source under MIT License\n\nCopyright (c) 2013 Grady O'Connell\n\n## async\n- Coroutines w/ YIELD(), AWAIT(), and SLEEP()\n- Channels\n- Async Sockets\n- Event Multiplexer\n\n```c++\n// MX thread 0, void future\nMX[0].coro\u003cvoid\u003e([]{\n    // do async stuff\n    auto foo = AWAIT(bar);\n\n    // async sleep yield\n    SLEEP(chrono::milliseconds(100));\n});\n```\n\n```c++\n// socket example\nMX[0].coro\u003cvoid\u003e([\u0026]{\n    for(;;)\n    {\n        auto client = make_shared\u003cTCPSocket\u003e(AWAIT(server-\u003eaccept()));\n        \n        // coroutine per client\n        MX[0].coro\u003cvoid\u003e([\u0026, client]{\n            int client_id = client_ids++;\n            LOGf(\"client %s connected\", client_id);\n            try{\n                for(;;)\n                    AWAIT(client-\u003esend(AWAIT(client-\u003erecv())));\n            }catch(const socket_exception\u0026 e){\n                LOGf(\"client %s disconnected (%s)\", client_id % e.what());\n            }\n        });\n    }\n});\n\n```\n\n## reactive\nsignals, reactive values (signal-paired vars), and lazy evaluation\n\n## meta\nJSON-compatible serializable meta-objects, property trees\n\n## freq\nTimelines, alarms, animation/easing, waypoints/keyframes, interpolation\n\n## log\nLogger w/ error handling, thread-safe scoped indent, silencing, and capturing\n\n## math\nsome math stuff to use with glm\n\n## common (kit.h)\nCommon stuff used by other modules, including:\n\n- freezable: freeze objects as immutable\n- make_unique: clone of c++14 function\n- dummy_mutex\n- ENTIRE() range macro\n- bit() and mask()\n- null_ptr_exception\n- scoped_unlock\n- thread-safe singleton\n- timed function auto-retry\n- index data structures w/ unused ID approximation\n\n","funding_links":[],"categories":["Libraries"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflipcoder%2Fkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fflipcoder%2Fkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fflipcoder%2Fkit/lists"}