{"id":1801,"url":"https://github.com/Carthage/ReactiveTask","last_synced_at":"2025-08-02T04:32:32.285Z","repository":{"id":24017733,"uuid":"27402149","full_name":"Carthage/ReactiveTask","owner":"Carthage","description":"Flexible, stream-based abstraction for launching processes","archived":false,"fork":false,"pushed_at":"2019-11-08T07:52:23.000Z","size":312,"stargazers_count":131,"open_issues_count":2,"forks_count":26,"subscribers_count":12,"default_branch":"master","last_synced_at":"2025-07-20T13:05:42.892Z","etag":null,"topics":["reactiveswift","swift"],"latest_commit_sha":null,"homepage":"","language":"Swift","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/Carthage.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-12-01T22:01:30.000Z","updated_at":"2025-02-21T23:31:08.000Z","dependencies_parsed_at":"2022-08-22T09:01:08.011Z","dependency_job_id":null,"html_url":"https://github.com/Carthage/ReactiveTask","commit_stats":null,"previous_names":[],"tags_count":28,"template":false,"template_full_name":null,"purl":"pkg:github/Carthage/ReactiveTask","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Carthage%2FReactiveTask","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Carthage%2FReactiveTask/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Carthage%2FReactiveTask/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Carthage%2FReactiveTask/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Carthage","download_url":"https://codeload.github.com/Carthage/ReactiveTask/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Carthage%2FReactiveTask/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":268334618,"owners_count":24233793,"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":["reactiveswift","swift"],"created_at":"2024-01-05T20:15:56.127Z","updated_at":"2025-08-02T04:32:32.011Z","avatar_url":"https://github.com/Carthage.png","language":"Swift","readme":"# ReactiveTask\nReactiveTask is a Swift framework for launching shell tasks (processes), built using [ReactiveSwift](https://github.com/ReactiveCocoa/ReactiveSwift).\n\n```swift\nlet strings = [ \"foo\\n\", \"bar\\n\", \"buzz\\n\", \"fuzz\\n\" ]\nlet input = SignalProducer\u003cData, NoError\u003e(values: strings.map { $0.data(using: .utf8)! })\nlet task = Task(\"/usr/bin/sort\")\n\n// Run the task, ignoring the output, and do something with the final result.\nlet result: Result\u003cString, TaskError\u003e? = task.launch(standardInput: input)\n    .ignoreTaskData()\n    .map { String(data: $0, encoding: .utf8) }\n    .ignoreNil()\n    .single()\nprint(\"Output of `\\(task)`: \\(result?.value ?? \"\")\")\n\n// Start the task and print all the events, which includes all the output\n// that was received.\ntask.launch(standardInput: input)\n    .flatMapTaskEvents(.concat) { data in\n        return SignalProducer(value: String(data: data, encoding: .utf8))\n    }\n    .startWithNext { (event: TaskEvent) in\n        switch event {\n        case let .launch(task):\n            print(\"launched task: \\(task)\")\n\n        case let .standardError(data):\n            print(\"stderr: \\(data)\")\n\n        case let .standardOutput(data):\n            print(\"stdout: \\(data)\")\n\n        case let .success(string):\n            print(\"value: \\(string ?? \"\")\")\n        }\n    }\n```\n\nFor examples of how to use ReactiveTask, see the Xcode and Git integration code from the [CarthageKit](https://github.com/Carthage/Carthage) framework.\n\n## License\nReactiveTask is released under the [MIT license](LICENSE.md).\n","funding_links":[],"categories":["Reactive Programming"],"sub_categories":["Other free courses","Prototyping","Other Parsing"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCarthage%2FReactiveTask","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FCarthage%2FReactiveTask","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCarthage%2FReactiveTask/lists"}