How to delete a file in Ruby

To delete a file in Ruby you can use the following snippet.

Sample Ruby

File.delete('filePath')  

Please Share us:
Please rate this snippet

One thought on “How to delete a file in Ruby

Leave a Reply