{"id":18038007,"url":"https://github.com/quantumsheep/ibenvo","last_synced_at":"2025-08-02T07:33:23.877Z","repository":{"id":96168107,"uuid":"168186224","full_name":"quantumsheep/ibenvo","owner":"quantumsheep","description":"Minimalistic event loop in C","archived":false,"fork":false,"pushed_at":"2019-01-30T15:22:32.000Z","size":20,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-05T00:41:15.220Z","etag":null,"topics":["c","event","loop","thread"],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/quantumsheep.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-01-29T16:19:22.000Z","updated_at":"2023-09-08T17:49:50.000Z","dependencies_parsed_at":null,"dependency_job_id":"55d2e37a-aa66-42be-8468-9b3628391042","html_url":"https://github.com/quantumsheep/ibenvo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/quantumsheep/ibenvo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quantumsheep%2Fibenvo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quantumsheep%2Fibenvo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quantumsheep%2Fibenvo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quantumsheep%2Fibenvo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/quantumsheep","download_url":"https://codeload.github.com/quantumsheep/ibenvo/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/quantumsheep%2Fibenvo/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268348651,"owners_count":24236298,"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","status":"online","status_checked_at":"2025-08-02T02:00:12.353Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["c","event","loop","thread"],"created_at":"2024-10-30T13:14:38.247Z","updated_at":"2025-08-02T07:33:23.852Z","avatar_url":"https://github.com/quantumsheep.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# What is an event loop?\nBasically, an event loop is a state where a program runs indefinitely and waits for some events to be triggered. In this library, each time an event is emitted, the defined listeners callbacks will be started as a thread, which means that the program will execute instructions asynchronously!\n\nThis library makes use of [worker library](https://github.com/QuantumSheep/worker-c).\n\n# How to use\nWell, you don't have a lot of functions:\n- `ev_emitter_init()` which instantiate an `EventEmitter *`. Use this function before using any other functions that requires an `EventEmitter`, else it will just doesn't work.\n- `ev_on(EventEmitter *ev, char *event, void (*cb)(void *)))` can be used to add a listener to a given event. The callback function (`cb`) will be launched if the given event is emitted. Events are stored in a chained list style to take care of your RAM.\n- `ev_emit(EventEmitter *ev, char *event, void *args)` is the emitter, when you launch this function, it will loop over all events who are listening in the `EventEmitter` (`ev`) and launch the callbacks that match the given event.\n- `ev_loop()` will just loop indefinitely, it's literally a `while(1)` loop. Put it at the end of your program.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquantumsheep%2Fibenvo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fquantumsheep%2Fibenvo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fquantumsheep%2Fibenvo/lists"}