chmod(mode, *files)
public
Changes permission bits on files to the bit pattern represented by
mode. If the last parameter isn’t a String, verbose mode will be enabled.
File.chmod 0755, 'somecommand'
File.chmod 0644, 'my.rb', 'your.rb', true
Show source
def chmod(mode, *files)
verbose = if files[-1].is_a? String then false else files.pop end
$stderr.printf "chmod %04o %s\n", mode, files.join(" ") if verbose
o_chmod mode, *files
end