Difference between revisions of "Detox"

From SME Server
Jump to navigationJump to search
(Detox package)
(No difference)

Revision as of 14:38, 9 March 2022

Version

Contrib 10:
detox
The latest version of detox is available in the SME repository, click on the version number(s) for more information.


Installation

Koozali SME v10

yum install --enablerepo=smecontribs detox

Description

The detox utility renames files to make them easier to work with. It removes spaces and other such annoyances. It'll also translate or cleanup Latin-1 (ISO 8859-1) characters encoded in 8-bit ASCII, Unicode characters encoded in UTF-8, and CGI escaped characters.

Usage

Detox is driven by a configurable series of filters, called a sequence. Sequences are covered in more detail in detoxrc(5) and are discoverable with the -L option. Some examples of default sequences are iso8859_1 and utf_8

Please read the man file for more information.

Examples

Will run the sequence iso8859_1 recursively, listing any changes, without changing anything, on the files of /tmp/new_files

detox -s iso8859_1 -r -v -n /tmp/new_files

Will list the sequences within my_detoxrc showing their filters and options.

detox -c my_detoxrc -L -v

From default rc file /etc/detoxrc we can see:

#
# Default sequence
#
sequence default {

utf_8; safe; wipeup;

};

Simple test

mkdir -p /tmp/test
cd /tmp/test
touch "some file.txt"

Use verbose and dry-run mode:

detox --r -v -n /tmp/test
Scanning: /tmp/test
/tmp/test/some file.txt -> /tmp/test/some_file.txt


Removal

yum remove detox

Bugs

Please raise bugs under the SME-Contribs section in bugzilla and select the detox component or use this link .

"No open bugs found."


Changelog

Only versions released in smecontrib are listed here.