Hi,
Could anyone please tell me how can I write to a file which already contains some data without erasing any previous data?
Afan.
···
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
Hi,
Could anyone please tell me how can I write to a file which already contains some data without erasing any previous data?
Afan.
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
Could anyone please tell me how can I write to a file which already
contains some data without erasing any previous data?
open it with "a", for example
svg% cat aa
a
svg%
svg% ruby -e 'File.open("aa", "a") {|f| f.puts "b"}'
svg%
svg% cat aa
a
b
svg%
Guy Decoux