{"id":13648574,"url":"https://github.com/alexcrichton/wait-timeout","last_synced_at":"2025-05-15T16:07:47.675Z","repository":{"id":49429978,"uuid":"42080731","full_name":"alexcrichton/wait-timeout","owner":"alexcrichton","description":"Waiting on a child process with a timeout in Rust","archived":false,"fork":false,"pushed_at":"2025-02-03T14:58:45.000Z","size":636,"stargazers_count":69,"open_issues_count":5,"forks_count":18,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-03T02:52:18.853Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alexcrichton.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-APACHE","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":"2015-09-08T00:26:36.000Z","updated_at":"2025-02-11T11:05:36.000Z","dependencies_parsed_at":"2024-06-14T21:56:56.828Z","dependency_job_id":"eaaf7b03-7422-4d95-83ec-9a14a85928d4","html_url":"https://github.com/alexcrichton/wait-timeout","commit_stats":{"total_commits":57,"total_committers":10,"mean_commits":5.7,"dds":0.3157894736842105,"last_synced_commit":"2a4f0f2e85768735575558b0e97e6c35df815e97"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexcrichton%2Fwait-timeout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexcrichton%2Fwait-timeout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexcrichton%2Fwait-timeout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexcrichton%2Fwait-timeout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alexcrichton","download_url":"https://codeload.github.com/alexcrichton/wait-timeout/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254047250,"owners_count":22005761,"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":[],"created_at":"2024-08-02T01:04:21.677Z","updated_at":"2025-05-15T16:07:42.665Z","avatar_url":"https://github.com/alexcrichton.png","language":"Rust","funding_links":[],"categories":["Rust"],"sub_categories":[],"readme":"# wait-timeout\n\n[![Build Status](https://github.com/alexcrichton/wait-timeout/actions/workflows/main.yml/badge.svg?branch=master)](https://github.com/alexcrichton/wait-timeout/actions/workflows/main.yml)\n\n[Documentation](https://docs.rs/wait-timeout)\n\nRust crate for waiting on a `Child` process with a timeout specified.\n\n```sh\n$ cargo add wait-timeout\n```\n\nExample:\n\n```rust\nuse std::io;\nuse std::process::Command;\nuse std::time::{Duration, Instant};\nuse wait_timeout::ChildExt;\n\nfn main() -\u003e io::Result\u003c()\u003e {\n    let mut child = Command::new(\"sleep\").arg(\"100\").spawn()?;\n\n    let start = Instant::now();\n    assert!(child.wait_timeout(Duration::from_millis(100))?.is_none());\n    assert!(start.elapsed() \u003e Duration::from_millis(100));\n\n    child.kill()?;\n\n    let start = Instant::now();\n    assert!(child.wait_timeout(Duration::from_millis(100))?.is_some());\n    assert!(start.elapsed() \u003c Duration::from_millis(100));\n\n    Ok(())\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexcrichton%2Fwait-timeout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexcrichton%2Fwait-timeout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexcrichton%2Fwait-timeout/lists"}