Skip to main content

Command line tool to nuke a directory

Project description

https://img.shields.io/pypi/v/nuke.svg https://img.shields.io/pypi/l/nuke.svg https://img.shields.io/pypi/wheel/nuke.svg https://img.shields.io/pypi/pyversions/nuke.svg https://img.shields.io/badge/Say%20Thanks-!-1EAEDB.svg

Command line tool for nuking a directory 💥.

Installation

Installing nuke is intended to be super easy. The only dependency is a supported Python interpreter. You can get nuke via pip:

$ pip install nuke

nuke is supported for Python versions 2.7, 3.5 & 3.6+.

Usage

The most common usage of nuke is when you wish to recreate a build directory for a build program such as CMake.

To use nuke, you just call nuke from the command line and specify the directory you wish to nuke:

$ nuke path/to/directory

If you are already in the directory you wish to nuke, you don’t need to exit the directory. Calling nuke without any arguments will nuke the current directory:

$ nuke  # same as "nuke ."

Since nuking is a dangerous operation and you don’t want to inadvertently delete something important, nuke always asks you to confirm the nuking of a directory. If you wish to override this since you know what you are doing or you wish to use nuke in a shell script, you can pass in the -y flag:

$ nuke -y /path/to/dir/

You can also specify a .nukeignore file inside the directory to be nuked. This works similar to the .gitignore file. Every file that matches a pattern in the .nukeignore is ignored and spared from a gruesome fate of its eligible siblings.

For example:

*.py

will result in all .py files not being nuked.

Version History

2.1.0

Migrated from clint to click to streamline code. Added -l flag to list files that will be deleted without deleting them.

2.0.0

Added feature to ignore files to nuke based on a .nukeignore file on a per directory level.

1.0.5

Minor bug fixes.

1.0

Nuke is out!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nuke-2.1.1.tar.gz (4.3 kB view details)

Uploaded Source

File details

Details for the file nuke-2.1.1.tar.gz.

File metadata

  • Download URL: nuke-2.1.1.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for nuke-2.1.1.tar.gz
Algorithm Hash digest
SHA256 773b987002ea279deca2249bf80a90a5e3fd1c5faa7bd4ebca43fceee73276a8
MD5 e57a8979205410c6daeed38a10319d60
BLAKE2b-256 77f8c5c42f02c76c682e2d23b67dc2aae3839d783d71721ca47a119d31c1a0ac

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page