This package has been deprecated

Author message:

Deprecated in favor of the `trash` module

xdg-trash

2.0.2 • Public • Published

xdg-trash Build Status

Safely move files and directories to trash on Linux

Install

$ npm install --save xdg-trash

Usage

const xdgTrash = require('xdg-trash');
 
xdgTrash(['foo.txt', 'bar.tar']).then(() => {
    console.log('Files successfully moved to trash!');
});

API

xdgTrash(files)

Move files to trash. Returns a promise that resolves to an array containing the removed files.

files

Required
Type: array

Files to be moved to trash.

CLI

See the trash CLI.

License

MIT © Kevin Mårtensson

Package Sidebar

Install

npm i xdg-trash

Weekly Downloads

484

Version

2.0.2

License

MIT

Last publish

Collaborators

  • kevva
  • sindresorhus