it’s a ruby question, i posted here 'cause you have to make an account
to post on ruby section.
is there an easy way in ruby to delete a folder which is not empty?
Dir.delete( folder ) deletes an empty folder, raises error otherwise.
it’s a ruby question, i posted here 'cause you have to make an account
to post on ruby section.
is there an easy way in ruby to delete a folder which is not empty?
Dir.delete( folder ) deletes an empty folder, raises error otherwise.
If you’re on *nix, rm -rf #{path_to_folder}
should work fine.
Vish
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.
Sponsor our Newsletter | Privacy Policy | Terms of Service | Remote Ruby Jobs