Empty the trash
JavaScript
Clone or download

readme.md

empty-trash Build Status

Empty the trash

Works on macOS, Linux, and Windows.

Install

$ npm install --save empty-trash

Usage

const emptyTrash = require('empty-trash');

emptyTrash().then(() => {
	console.log('done');
});

Info

On macOS, AppleScript is used as it's the only way to do it without incurring permission issues.

On Linux, the XDG spec is followed.

On Windows, recycle-empty-bin is used.

Related

License

MIT © Sindre Sorhus