{"id":28353580,"url":"https://github.com/eschwart/nicesync-rs","last_synced_at":"2025-10-10T18:14:26.368Z","repository":{"id":290819068,"uuid":"665891776","full_name":"eschwart/nicesync-rs","owner":"eschwart","description":"Rust Concurrency and Thread Blocking","archived":false,"fork":false,"pushed_at":"2023-07-13T08:27:09.000Z","size":2,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-04T07:57:22.994Z","etag":null,"topics":["blocking","concurrency","rust","threads"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eschwart.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,"zenodo":null}},"created_at":"2023-07-13T08:27:07.000Z","updated_at":"2023-07-13T08:28:49.000Z","dependencies_parsed_at":"2025-04-30T18:39:02.149Z","dependency_job_id":"d2d0aa45-51d8-403c-8408-168f17be21ac","html_url":"https://github.com/eschwart/nicesync-rs","commit_stats":null,"previous_names":["eschwart/nicesync-rs"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/eschwart/nicesync-rs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eschwart%2Fnicesync-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eschwart%2Fnicesync-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eschwart%2Fnicesync-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eschwart%2Fnicesync-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eschwart","download_url":"https://codeload.github.com/eschwart/nicesync-rs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eschwart%2Fnicesync-rs/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261217237,"owners_count":23126245,"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":["blocking","concurrency","rust","threads"],"created_at":"2025-05-28T01:12:41.548Z","updated_at":"2025-10-10T18:14:26.263Z","avatar_url":"https://github.com/eschwart.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# nicesync-rs\n\n## Description\nThis is a just quick and short demonstration of my understanding of concurrency and conditional thread blocking utilizing the [CondVar](https://doc.rust-lang.org/std/sync/struct.Condvar.html) functionality in the [rust](https://www.rust-lang.org/) programming language.\n\n## Usage\nWhen you run the program it'll continuously read input through *stdin*. Enter `69` to have the word \"hehe\" written to the terminal. To exit to program, either enter `420` or just leave with `CTRL-C`.\n\n## How it works\nWhen starting the program, before initiating any sort of input through `stdin`, an external thread is initialized which essentially does nothing, consuming no CPU time, until a certain variable is changed. While the thread is blocked, the main thread asks for the user to input shit. If the user inputs a `69` or `420` the variable is modified and then the external thread is *notified* of the modification of the shared variable. Upon notification, the external thread wakes and checks if the shared variable was modified to a particular value. If all goes well, the external thread completes its little sub-task and continues to loop, of course until a `420` is entered where it would then end itself.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feschwart%2Fnicesync-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feschwart%2Fnicesync-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feschwart%2Fnicesync-rs/lists"}