generally this is more difficult and different than under Windows OSes. Linux offers a lot more file systems than Windows does which may be a main reason that there's mostly no unified concept of a "recycle bin" on the file system layer. The only undelete tool I know is for ext2 file systems. I guess there are more tools but probably they are specific to one file system.
The other way is how the Windows recycle bin probably works, too. Graphical desktop environments like Gnome or KDE have a concept of a recycle bin where you can undelete files etc. But for this to work you also have to use the recycle bin to delete files or directories. If you delete them directly without the recycle bin knowing it they are gone forever (without special tools).
I hope this makes it a little clearer
Marco [ May 28, 2008: Message edited by: Marco Ehrentreich ]
It's actually a lot like Windows. If you delete a file from CMD or COMMAND.EXE or a Windows application, it doesn't go into a recycle bin either. Likewise it probably won't go into a recycle bin if it's on a network drive.
The concept of a recycle bin is something that is generally done at the GUI desktop level, so if you delete a file any other way it normally won't get saved. That's just tradition, however. There's no reason why a Linux filesystem couldn't be made to support a bin at the OS level. In fact, with the Userspace file system, you could probably easily implement a facade for the ext2/3 or other filesystem(s) of your choice that converted deletion operations into "move to recycle bin directory" operations.
The really fun thing about Linux, however, is that unlike Windows, there's more than one Desktop manager to choose from and no real standard on where they should put their recycle bins (if any). It's usually a hidden directory in your desktop or home directory, however .
An IDE is no substitute for an Intelligent Developer.