[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Re: prob with File.open and perms

Peña, Botp

1/27/2007 8:17:00 AM

pls ignore my post below. it's terrible. i should have deleted the outputted file before running the program again.

nobu's post is the_ answer.

In this regard, may i suggest a feature for documenting methods

from File.new(filename [, mode [, perm]]) => file

to File.new(filename => String
[, mode = File::WRONLY => Integer in File IO
[, perm = 0644 => Integer in octal form]]
)
=> file in IO

or something like that. A quick glance, we'd know more about the parameters..

sorry for the noise,
kind regards -botp


# -----Original Message-----
# From: Peña, Botp [mailto:botp@delmonte-phil.com]
# Sent: Saturday, January 27, 2007 3:14 PM
# To: ruby-talk ML
# Subject: Re: prob with File.open and perms
#
# From: Une Bévue [mailto:unbewusst.sein@google.com.invalid]
# # i get the following perms :
# # --w----r--
# #
#
# Hi Une,
#
# it works for me.
#
# #----------
# root@pc4all:~# cat test3.rb
# File.open('a_file',File::WRONLY|File::TRUNC|File::CREAT,644) do |f|
# f.print 'something else'
# end
# root@pc4all:~# ruby test3.rb
#
# root@pc4all:~# ll a_file
# -rw-r--r-- 1 root root 14 Jan 27 15:07 a_file
#
# root@pc4all:~# ruby -v; uname -an
# ruby 1.8.5 (2006-12-21 patchlevel 5000) [i686-linux]
# Linux pc4all 2.6.15-27-686 #1 SMP PREEMPT Fri Dec 8 18:00:07
# UTC 2006 i686 GNU/Linux
# #----------
#
# kind regards -botp
#
#
#
#
#

2 Answers

unbewusst.sein

1/27/2007 8:55:00 AM

0

Peña, Botp <botp@delmonte-phil.com> wrote:

> sorry for the noise,

no prob at all, u've tried to answer something !
--
Artaban de Médée

Buster Norris

1/20/2012 1:15:00 AM

0

Summary: Not only the most prolific liar also the most prolific thief
of other's writings. She is also a Stolen Valor stain on America. Note
that when you reply to a Proven Liar you encourage them to continue
lying.

[][][][][][]


The DemocRAT Hall Of Shame http://www.democrathallof... asks
"Why do you always LIE?"

[Courtesy of Buster Norris]

On Fri, 30 Dec 2011 11:57:59 -0500, Kickin' Ass and Takin' Names
<PopUlist349@hotmail.com> wrote:
>The middle class was built by guvmint programs:
>-- post-WW II GI bill that enabled millions of vets to obtain college
>or technical degrees (and was opposed by the GOP)

LIAR!!!!!!!!!!!!!!!!

Harry W. Colmery, a World War I veteran and the former Republican
National Committee chairman, wrote the first draft of the G.I. Bill.
U.S. Senator Ernest McFarland, D-Arizona, was actively involved in the
bill's passage and is known, with Warren Atherton, as one of the
"fathers of the G.I. Bill." One might then term Edith Nourse Rogers,
R-Mass., who helped write and who co-sponsored the legislation, as the
"mother of the G.I. Bill".
The bill was introduced in the House on January 10, 1944, and in the
Senate the following day. Both chambers approved their own versions of
the bill.
http://en.wikipedia.org/wiki...

Posted from:
The DemocRATs Hall of Shame!
http://www.democrathallof...