Skip to main content

Command line tool to nuke a directory

Project description

version license wheel python say-thanks

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 :code: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 :code: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.

Suppose you just want to see what files will be nuked without actually deleting them, you can then run nuke -l /path/to/dir, and this will print out the directory tree of all the files that will be nuked.

Version History

2.2.1

Fixed bug in the -l list functionality so that ignored files are not displayed.

2.2.0

Major bugfix in the .nukeignore functionality. nuke now ignores whole directories if the pattern ends in a slash (/). Also, -l prints out files as a directory tree.

2.1.1

Updated Python Trove Classifiers.

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.2.1.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

nuke-2.2.1-py3.6.egg (8.6 kB view details)

Uploaded Egg

File details

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

File metadata

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

File hashes

Hashes for nuke-2.2.1.tar.gz
Algorithm Hash digest
SHA256 d6dca709b2f86208c3be51d0892501a60c06fea6b5bab97749a1b102b5f21f6c
MD5 d405e8d722cf6e0122f7a6fc49408fa3
BLAKE2b-256 58538699efd8b754d7e25f6be8c9877ed122d145002353da3019807d2b61b3a7

See more details on using hashes here.

File details

Details for the file nuke-2.2.1-py3.6.egg.

File metadata

  • Download URL: nuke-2.2.1-py3.6.egg
  • Upload date:
  • Size: 8.6 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for nuke-2.2.1-py3.6.egg
Algorithm Hash digest
SHA256 fe9862827cdd9e4793a8cde28ca732afcc8515eda5b25ff80e02b6f72571a596
MD5 80675552884fb1f3e0aa8a6068808ff5
BLAKE2b-256 af97abdbceb0203940ac840646664f3168bac576c6ebb48fc460ba25ca1412cc

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