108

Ok for the recursive options when deleting files, but what is rimraf? Is it an acronym? Does it come from words combination?

The word is fairly pleasant, I would like to know where does it come from.

Nikita Fedyashev
  • 15,938
  • 11
  • 41
  • 69
Joseph Merdrignac
  • 2,212
  • 2
  • 16
  • 16
  • 2
    maybe [RimRaf](http://www.nikola-breznjak.com/blog/javascript/nodejs/how-to-delete-node_modules-folder-on-windows-machine/). Seems it is just easy to pronounce _rimraf_ than _rm -rf_ – boop_the_snoot Jul 24 '17 at 08:55
  • 8
    I'd guess it originated as an attempt to pronounce "`rm -rf`" – jsheeran Jul 24 '17 at 08:57
  • 1
    Hehe @Joseph Merdrignac ... Funny thing is... being a writer among other things, I also find "the word is" (indeed) "fairly pleasant". Gonna name my next kid Rimraf :D. "Hey Rimraf, please remove all your toys from the floor. Recursively!" --- It's going to be a great success :D. – Axonn Sep 30 '20 at 07:45

4 Answers4

97

Rimraf

The UNIX command rm -rf for Node.js

Deep deletion (like rm -rf) module for Node.js that provides asynchronous deep- deletion of files and directories.

The rimraf executable is a faster alternative to the rm -rf shell command.

(rm stands for remove, rf stands for recursive force.)

Source :

yaya
  • 4,522
  • 1
  • 19
  • 24
Arun Ravindranath
  • 1,241
  • 9
  • 14
  • 26
    One thing that has to be understood in the context of the rimraf context as an npm package is its intended usage. It's not like you can't rm -rf in Linux and call it a day, but Windows won't understand your intent. As such rather then thinking about it as a faster alias, you can think about it as a cross platform solution for the same problem: rm -rf. – Ghepes Doru Sep 26 '19 at 13:41
40

This is just a guess, but I would say that it is a way to pronounce the command rm -rf (remove, recursive, force removal).

Sebastian Redl
  • 61,331
  • 8
  • 105
  • 140
18

rimraf is an executable that is used to clean the installed node packages in a node based project. It basically executes the rm -rf command on the node_modules directory, but is a faster alternative.

Giacomo1968
  • 23,903
  • 10
  • 59
  • 92
ajay
  • 197
  • 1
  • 2
  • 21
    Why and how much is it faster than `rm -rf`? – k0pernikus Jul 02 '19 at 17:30
  • 2
    @k0pernikus around -50% (2 times slower than `rm -rf`) on my machine and for some others too, like measured here http://www.ashleysheridan.co.uk/blog/Why+You+Should+Not+Use+Rimraf ; sometimes there is no difference, and sometimes it's around 50 times slower than `rm -rf`, according to this issue: https://github.com/isaacs/rimraf/issues/142 – Pavlus Nov 08 '19 at 21:15
1

Like others have said, it's based on rm -rf. However, I think pronunciation sounds like it may come from the term riffraff, or perhaps even the rapper Riff Raff (just kidding).

And I say this as a possible explanation for the added "i" and "a" in "rimraf" since that coincides with the word riffraff.

notnoahkirby
  • 79
  • 2
  • 12