.\" DO NOT MODIFY THIS FILE!  It was generated by help2man 1.47.12.
.TH CLEANCSS "1" "February 2020" "cleancss 4.3.0" "User Commands"
.SH NAME
cleancss \- cleancss - fast and efficient CSS optimizer
.SH SYNOPSIS
.B cleancss
[\fI\,options\/\fR] \fI\,<source-file \/\fR...\fI\,>\/\fR
.SH OPTIONS
.TP
\fB\-v\fR, \fB\-\-version\fR
output the version number
.TP
\fB\-c\fR, \fB\-\-compatibility\fR [ie7|ie8]
Force compatibility mode (see Readme for
advanced examples)
.TP
\fB\-d\fR, \fB\-\-debug\fR
Shows debug information (minification time &
compression efficiency)
.TP
\fB\-f\fR, \fB\-\-format\fR <options>
Controls output formatting, see examples below
.TP
\fB\-o\fR, \fB\-\-output\fR [output\-file]
Use [output\-file] as output instead of STDOUT
.TP
\fB\-O\fR <n> [optimizations]
Turn on level <n> optimizations; optionally
accepts a list of fine\-grained options,
defaults to `1`, see examples below
.TP
\fB\-\-inline\fR [rules]
Enables inlining for listed sources (defaults
to `local`)
.TP
\fB\-\-inline\-timeout\fR [seconds]
Per connection timeout when fetching remote
stylesheets (defaults to 5 seconds)
.TP
\fB\-\-remove\-inlined\-files\fR
Remove files inlined in <source\-file ...> or
via `@import` statements
.TP
\fB\-\-skip\-rebase\fR
Disable URLs rebasing
.TP
\fB\-\-source\-map\fR
Enables building input's source map
.TP
\fB\-\-source\-map\-inline\-sources\fR
Enables inlining sources inside source maps
.TP
\fB\-\-input\-source\-map\fR [file]
Specifies the path of the input source map
file
.TP
\fB\-h\fR, \fB\-\-help\fR
output usage information
.IP
.SH Examples:
.TP
%> cleancss one.css
.TP
%> cleancss \fB\-o\fR one\-min.css one.css
.TP
%> cleancss \fB\-o\fR merged\-and\-minified.css one.css two.css three.css
.TP
%> cleancss one.css two.css three.css | gzip \fB\-9\fR \fB\-c\fR > merged\-minified\-and\-gzipped.css.gz
.IP
.SH Formatting options:
.TP
%> cleancss \fB\-\-format\fR beautify one.css
.TP
%> cleancss \fB\-\-format\fR keep\-breaks one.css
.TP
%> cleancss \fB\-\-format\fR 'indentBy:1;indentWith:tab' one.css
.TP
%> cleancss \fB\-\-format\fR 'breaks:afterBlockBegins=on;spaces:aroundSelectorRelation=on' one.css
.TP
%> # `breaks` controls where to insert breaks
.TP
%> #   `afterAtRule` controls if a line break comes after an at\-rule; e.g. `@charset`; defaults to `off` (alias to `false`)
.TP
%> #   `afterBlockBegins` controls if a line break comes after a block begins; e.g. `@media`; defaults to `off`
.TP
%> #   `afterBlockEnds` controls if a line break comes after a block ends, defaults to `off`
.TP
%> #   `afterComment` controls if a line break comes after a comment; defaults to `off`
.TP
%> #   `afterProperty` controls if a line break comes after a property; defaults to `off`
.TP
%> #   `afterRuleBegins` controls if a line break comes after a rule begins; defaults to `off`
.TP
%> #   `afterRuleEnds` controls if a line break comes after a rule ends; defaults to `off`
.TP
%> #   `beforeBlockEnds` controls if a line break comes before a block ends; defaults to `off`
.TP
%> #   `betweenSelectors` controls if a line break comes between selectors; defaults to `off`
.TP
%> # `indentBy` controls number of characters to indent with; defaults to `0`
.TP
%> # `indentWith` controls a character to indent with, can be `space` or `tab`; defaults to `space`
.TP
%> # `spaces` controls where to insert spaces
.TP
%> #   `aroundSelectorRelation` controls if spaces come around selector relations; e.g. `div > a`; defaults to `off`
.TP
%> #   `beforeBlockBegins` controls if a space comes before a block begins; e.g. `.block {`; defaults to `off`
.TP
%> #   `beforeValue` controls if a space comes before a value; e.g. `width: 1rem`; defaults to `off`
.TP
%> # `wrapAt` controls maximum line length; defaults to `off`
.IP
.SH Level 0 optimizations:
.TP
%> cleancss \fB\-O0\fR one.css
.IP
.SH Level 1 optimizations:
.TP
%> cleancss \fB\-O1\fR one.css
.TP
%> cleancss \fB\-O1\fR removeQuotes:off;roundingPrecision:4;specialComments:1 one.css
.TP
%> cleancss \fB\-O1\fR all:off;specialComments:1 one.css
.TP
%> # `cleanupCharsets` controls `@charset` moving to the front of a stylesheet; defaults to `on`
.TP
%> # `normalizeUrls` controls URL normalzation; default to `on`
.TP
%> # `optimizeBackground` controls `background` property optimizatons; defaults to `on`
.TP
%> # `optimizeBorderRadius` controls `border\-radius` property optimizatons; defaults to `on`
.TP
%> # `optimizeFilter` controls `filter` property optimizatons; defaults to `on`
.TP
%> # `optimizeFontWeight` controls `font\-weight` property optimizatons; defaults to `on`
.TP
%> # `optimizeOutline` controls `outline` property optimizatons; defaults to `on`
.TP
%> # `removeEmpty` controls removing empty rules and nested blocks; defaults to `on` (since 4.1.0)
.TP
%> # `removeNegativePaddings` controls removing negative paddings; defaults to `on`
.TP
%> # `removeQuotes` controls removing quotes when unnecessary; defaults to `on`
.TP
%> # `removeWhitespace` controls removing unused whitespace; defaults to `on`
.TP
%> # `replaceMultipleZeros` contols removing redundant zeros; defaults to `on`
.TP
%> # `replaceTimeUnits` controls replacing time units with shorter values; defaults to `on
.TP
%> # `replaceZeroUnits` controls replacing zero values with units; defaults to `on`
.TP
%> # `roundingPrecision` rounds pixel values to `N` decimal places; `off` disables rounding; defaults to `off`
.TP
%> # `selectorsSortingMethod` denotes selector sorting method; can be `natural` or `standard`; defaults to `standard`
.TP
%> # `specialComments` denotes a number of /*! ... */ comments preserved; defaults to `all`
.TP
%> # `tidyAtRules` controls at\-rules (e.g. `@charset`, `@import`) optimizing; defaults to `on`
.TP
%> # `tidyBlockScopes` controls block scopes (e.g. `@media`) optimizing; defaults to `on`
.TP
%> # `tidySelectors` controls selectors optimizing; defaults to `on`
.IP
.SH Level 2 optimizations:
.TP
%> cleancss \fB\-O2\fR one.css
.TP
%> cleancss \fB\-O2\fR mergeMedia:off;restructureRules:off;mergeSemantically:on;mergeIntoShorthands:off one.css
.TP
%> cleancss \fB\-O2\fR all:off;removeDuplicateRules:on one.css
.TP
%> # `mergeAdjacentRules` controls adjacent rules merging; defaults to `on`
.TP
%> # `mergeIntoShorthands` controls merging properties into shorthands; defaults to `on`
.TP
%> # `mergeMedia` controls `@media` merging; defaults to `on`
.TP
%> # `mergeNonAdjacentRules` controls non\-adjacent rule merging; defaults to `on`
.TP
%> # `mergeSemantically` controls semantic merging; defaults to `off`
.TP
%> # `overrideProperties` controls property overriding based on understandability; defaults to `on`
.TP
%> # `reduceNonAdjacentRules` controls non\-adjacent rule reducing; defaults to `on`
.TP
%> # `removeDuplicateFontRules` controls duplicate `@font\-face` removing; defaults to `on`
.TP
%> # `removeDuplicateMediaBlocks` controls duplicate `@media` removing; defaults to `on`
.TP
%> # `removeDuplicateRules` controls duplicate rules removing; defaults to `on`
.TP
%> # `removeEmpty` controls removing empty rules and nested blocks; defaults to `on` (since 4.1.0)
.TP
%> # `removeUnusedAtRules` controls unused at rule removing; defaults to `off` (since 4.1.0)
.TP
%> # `restructureRules` controls rule restructuring; defaults to `off`
.TP
%> # `skipProperties` controls which properties won't be optimized, defaults to empty list which means all will be optimized (since 4.1.0)