Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

safe-wipe

Package Overview
Dependencies
Maintainers
2
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

safe-wipe - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

2

index.js

@@ -195,3 +195,3 @@ 'use strict';

return readdir(dir).then(function (files) {
files.filter(function (file) {
files = files.filter(function (file) {
return config.ignore.indexOf(file) === -1;

@@ -198,0 +198,0 @@ });

{
"name": "safe-wipe",
"version": "0.2.2",
"version": "0.2.3",

@@ -5,0 +5,0 @@ "homepage": "https://github.com/themeleon/safe-wipe",

@@ -21,19 +21,19 @@ # safe-wipe [![npm version](http://img.shields.io/npm/v/safe-wipe.svg?style=flat-square)](https://www.npmjs.org/package/safe-wipe)

| Name | Description |
| ---- | ----------- |
| `stdin`, `stdout`, `stderr` | Streams to use for I/O. Defaults to the `process` streams. |
| `ignore` | An array of files to ignore when checking if a directory is empty. Defaults to `.DS_Store` and `Thumbs.db`. |
| `parent` | A (supposed) parent directory of the directory to wipe. If the parent is contained in the directory to wipe, the process will be aborted in all cases. |
| `interactive` | Whether the session is interactive. `true` by default. |
| `force` | Whether to force the wipe if the folder is not empty. `false` by default. |
| `silent` | The error messages are not printed if this is et to `true`. `false` by default. |
| `messages` | An object of messages for user prompt and error display. |
| Name | Description | Default |
|-----------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------|-----------------------------|
| `stdin`, `stdout`, `stderr` | Streams to use for I/O. | `process.*` streams |
| `ignore` | An array of files to ignore when checking if a directory is empty. | `.DS_Store` and `Thumbs.db` |
| `parent` | A (supposed) parent directory of the directory to wipe. If the parent is contained in the directory to wipe, the process will be aborted in all cases. | |
| `interactive` | Whether the session is interactive. | `true` |
| `force` | Whether to force the wipe if the folder is not empty. | `false` |
| `silent` | The error messages are not printed if this is et to `true`. | `false` |
| `messages` | An object of messages for user prompt and error display. | |
The messages are:
| Name | Description |
| ---- | ----------- |
| Name | Description |
|-------------|-------------------------------------------------------------------------------------|
| `contained` | Error message when the folder to wipe is contained in the configured parent folder. |
| `confirm` | Text to prompt the user to confirm the (not empty) directory wipe. |
| `abort` | Error message when the user refuses to wipe the folder. |
| `confirm` | Text to prompt the user to confirm the (not empty) directory wipe. |
| `abort` | Error message when the user refuses to wipe the folder. |

@@ -44,6 +44,6 @@ The function is asynchronous and return a promise. Nothing is passed to

| Code | Description |
| ---- | ----------- |
| `CONTAINED` | Refused to remove the directory since it's containing the supposed parent. |
| `ABORT` | The user aborted the operation (or we're not in an interactive session and `config.force` is `false`). |
| Code | Description |
|-------------|--------------------------------------------------------------------------------------------------------|
| `CONTAINED` | Refused to remove the directory since it's containing the supposed parent. |
| `ABORT` | The user aborted the operation (or we're not in an interactive session and `config.force` is `false`). |

@@ -50,0 +50,0 @@ Examples

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc