{"id":16209215,"url":"https://github.com/gilzoide/unity-main-thread-task","last_synced_at":"2026-02-27T00:32:59.435Z","repository":{"id":70590851,"uuid":"529025666","full_name":"gilzoide/unity-main-thread-task","owner":"gilzoide","description":"Task/UniTask-based Main Thread dispatcher classes, no GameObjects involved","archived":false,"fork":false,"pushed_at":"2022-08-25T23:20:50.000Z","size":8,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-28T23:37:29.562Z","etag":null,"topics":["main-thread","mainthread","task","unitask","unity","unity3d"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"unlicense","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gilzoide.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2022-08-25T21:37:44.000Z","updated_at":"2025-02-23T16:25:11.000Z","dependencies_parsed_at":"2023-06-09T22:00:34.142Z","dependency_job_id":null,"html_url":"https://github.com/gilzoide/unity-main-thread-task","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gilzoide/unity-main-thread-task","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gilzoide%2Funity-main-thread-task","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gilzoide%2Funity-main-thread-task/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gilzoide%2Funity-main-thread-task/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gilzoide%2Funity-main-thread-task/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gilzoide","download_url":"https://codeload.github.com/gilzoide/unity-main-thread-task/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gilzoide%2Funity-main-thread-task/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29879043,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-26T23:51:21.483Z","status":"ssl_error","status_checked_at":"2026-02-26T23:50:46.793Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["main-thread","mainthread","task","unitask","unity","unity3d"],"created_at":"2024-10-10T10:28:42.364Z","updated_at":"2026-02-27T00:32:59.408Z","avatar_url":"https://github.com/gilzoide.png","language":"C#","readme":"# Main Thread Task\n[Task](https://docs.microsoft.com/en-us/dotnet/api/system.threading.tasks.task)/[UniTask](https://github.com/Cysharp/UniTask)-based\nMain Thread dispatcher classes, no `GameObject`s involved.\n\n\n## Features\n- Simple to use: call `MainThreadTask.Run` and that's it, your action will run on the Main Thread!\n- `async` method `MainThreadTask.RunAsync`, so you can `await` for execution to complete\n- [TaskScheduler](https://docs.microsoft.com/en-us/dotnet/api/system.threading.tasks.taskscheduler)\n  and [TaskFactory](https://docs.microsoft.com/en-us/dotnet/api/system.threading.tasks.taskfactory)\n  used for running Tasks on the Main Thread are available\n- UniTask-based implementation in `MainThreadUniTask` class, conditionally compiled if UniTask is\n  detected in project\n- `System.Action` extension methods `InvokeOnMainThread` and `InvokeOnMainThreadAsync`\n- No `GameObject`s involved\n- Simple implementations with around 50 lines of code each\n\n\n## How to install\nEither:\n\n- Install via [Unity Package Manager](https://docs.unity3d.com/Manual/upm-ui-giturl.html)\n  using the following URL:\n\n```\nhttps://github.com/gilzoide/unity-main-thread-task.git#1.0.0\n```\n\n- Copy the implementation file [Runtime/MainThreadTask.cs](Runtime/MainThreadTask.cs) and/or [Runtime/MainThreadUniTask.cs](Runtime/MainThreadUniTask.cs) to your project.\n  \n  If using UniTask, either remove the `#if/#endif` lines from `MainThreadUniTask.cs` or define `HAVE_UNITASK` in your project's scripting define symbols.","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgilzoide%2Funity-main-thread-task","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgilzoide%2Funity-main-thread-task","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgilzoide%2Funity-main-thread-task/lists"}