Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ujihisa/tasks
This project is no longer active. See open5 instead. http://github.com/ujihisa/open5
https://github.com/ujihisa/tasks
Last synced: about 1 month ago
JSON representation
This project is no longer active. See open5 instead. http://github.com/ujihisa/open5
- Host: GitHub
- URL: https://github.com/ujihisa/tasks
- Owner: ujihisa
- Created: 2009-08-12T08:28:59.000Z (over 15 years ago)
- Default Branch: master
- Last Pushed: 2010-02-03T23:55:33.000Z (almost 15 years ago)
- Last Synced: 2024-09-23T13:07:25.268Z (about 2 months ago)
- Language: Ruby
- Homepage:
- Size: 74.2 KB
- Stars: 6
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Tasks -- Better Process Manager for Ruby
![Traffic Control](http://farm4.static.flickr.com/3118/3204377933_8c978370db.jpg)
## spawn
`tasks` provides `spawn` even in ruby 1.8.
require 'tasks'
include Taskspid = spawn './something.rb'
...
system "kill #{pid}"`spawn` is like system with `'&'` and it also returns the procces id.
## love_pact
`tasks` supports a couple to do a love pact.
require 'tasks'
include Tasksmaster_pid = spawn './master.rb'
slave_pid = spawn './slave.rb'fork do
love_pact master_pid, slave_pid
endIf a master died, the slave dies immediately.
Note that now `love_pact` works only in UNIX.