Forum: Ruby on Rails chmod

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
085ae5a82c93b396e9801d74c63c6eff?d=identicon&s=25 Nhila Dasgota (Guest)
on 2006-06-11 06:42
hi everybody, after some time dealing with file upload finally i have my
scvript working, the problem its that seems that the files are uploaded
with 600 permissions and i need to be 644 to be accesible to everyone.

So i tried to change the permisions of the files inside the folder where
are saved the uploaded files, i have this on the index action of my
controller so at fisrt time change the permissions when needed:

Dir["/public/images/publics/*"].each {|f| FileUtils.chmod(0664, f)}

But doesnt seems to work, no error or warnings and the files remains
with the old permissions and i have to change it manually by ftp, if
someone can give me a hand with how to change permissions inside a
folder from a controller ill be very happy and your help will be very
appreciated cause i have tried a lot and i cant make it work :(
085ae5a82c93b396e9801d74c63c6eff?d=identicon&s=25 Nhila Dasgota (Guest)
on 2006-06-11 21:18
Anyone? im stuck with this by 4 days now, i cant find a working example
in how to change file permissions, really if someone can help with this
ill be very very thankful.

Nhila :)
59de94a56fd2c198f33d9515d1c05961?d=identicon&s=25 Tom Mornini (Guest)
on 2006-06-11 21:38
(Received via mailing list)
http://tinyurl.com/klhy3

The second major entry should get you where you're going.

Is it possible you spent 4 days without using Google?

If so let me humbly recommend that you pull the Google
trigger sooner next time.

--
-- Tom Mornini
This topic is locked and can not be replied to.