JosephMCasey JosephMCasey - 2 months ago 14
Linux Question

Why does tar allow unhyphenated options?

When reading through

man tar
, you will see that nowhere is the tar command used without a hyphen. Why then does tar allow the following two commands to be valid:

tar c .
tar -c .


3.3 The Three Option Styles

There are three styles for writing operations and options to the command line invoking tar. The different styles were developed at different times during the history of tar. These styles will be presented below, from the most recent to the oldest.