chmod

File.chmod(mode_int, file_name, ... ) â integer
Class Public methods

Changes permission bits on the named file(s) to the bit pattern represented by mode_int. Actual effects are operating system dependent (see the beginning of this section). On Unix systems, see chmod(2) for details. Returns the number of files processed.

File.chmod(0644, "testfile", "out")   #=> 2
doc_ruby_on_rails
2015-04-06 09:38:51
Comments
Leave a Comment

Please login to continue.