Search
Project
General
Profile
Sign in
Register
Home
Projects
Help
Search
:
Ruby
All Projects
Ruby
Overview
Activity
Roadmap
Issues
Repository
Like
Download (435 Bytes)
Bug #9480
» main.rb
joshc (Josh C)
, 02/04/2014 11:55 PM
require
'open3'
watcher
=
File
.
join
(
File
.
dirname
(
__FILE__
),
'watcher.rb'
)
raise
ArgumentError
,
"File not found
#{
watcher
}
"
unless
File
.
exists?
(
watcher
)
cmdline
=
"ruby.exe '
#{
watcher
}
'"
stdin
,
wait_threads
=
Open3
.
pipeline_w
(
cmdline
)
Process
.
detach
(
wait_threads
[
0
].
pid
)
puts
"Launched
#{
wait_threads
[
0
].
pid
}
"
stdin
.
puts
(
Process
.
pid
)
stdin
.
puts
(
30
)
stdin
.
puts
(
'this is a long command line argument containing spaces'
)
stdin
.
close
« Previous
1
2
Next »
(1-1/2)
Loading...