Ruby/File Directory/chown
Материал из Wiki.crossplatform.ru
Версия от 17:57, 13 сентября 2010; ViGOur (Обсуждение | вклад)
You can change the owner and group of a file with the chown method
# It is like the Unix/Linux command chown. # You need superuser or root privileges to use this method. file = File.new( "books.txt", "r" ) file.chown( 109, 3333 ) # or: file = File.new( "books.txt", "r" ).chown( 109, 3333 )