diff options
author | DongHun Kwak <dh0128.kwak@samsung.com> | 2019-01-10 14:08:23 +0900 |
---|---|---|
committer | DongHun Kwak <dh0128.kwak@samsung.com> | 2019-01-10 14:36:56 +0900 |
commit | 3e04d82fa8da3f9c3077d4d06b334cdc2c947a61 (patch) | |
tree | 8682677660f63cc17352be86698a04f2e5d7ca95 /man/man1/dos2unix.pod | |
parent | a43ffe7b214336b5ff551c8965d6fd16c63b13ed (diff) | |
download | dos2unix-3e04d82fa8da3f9c3077d4d06b334cdc2c947a61.tar.gz dos2unix-3e04d82fa8da3f9c3077d4d06b334cdc2c947a61.tar.bz2 dos2unix-3e04d82fa8da3f9c3077d4d06b334cdc2c947a61.zip |
Imported Upstream version 7.4.0upstream/7.4.0
Change-Id: I567718db10506669896b057a505586ec6e1d18d7
Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
Diffstat (limited to 'man/man1/dos2unix.pod')
-rw-r--r-- | man/man1/dos2unix.pod | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/man/man1/dos2unix.pod b/man/man1/dos2unix.pod index 7d85d71..d95750c 100644 --- a/man/man1/dos2unix.pod +++ b/man/man1/dos2unix.pod @@ -105,6 +105,17 @@ Or in new file mode: dos2unix -n -- -foo out.txt +=item B<--allow-chown> + +Allow file ownership change in old file mode. + +When this option is used, the conversion will not be aborted when the user +and/or group ownership of the original file can't be preserved in old file +mode. Conversion will continue and the converted file will get the same new +ownership as if it was converted in new file mode. See also options C<-o> and +C<-n>. This option is only available if dos2unix has support for preserving +the user and group ownership of files. + =item B<-ascii> Convert only line breaks. This is the default conversion mode. @@ -382,6 +393,15 @@ of the converted file. The read/write permissions of the new file will be the permissions of the original file minus the umask(1) of the person who runs the conversion. +=item B<--no-allow-chown> + +Don't allow file ownership change in old file mode (default). + +Abort conversion when the user and/or group ownership of the original file +can't be preserved in old file mode. See also options C<-o> and C<-n>. This +option is only available if dos2unix has support for preserving the user +and group ownership of files. + =item B<-o, --oldfile FILE ...> Old file mode. Convert file FILE and overwrite output to it. The program @@ -396,6 +416,27 @@ the file any more. Change of group could be a security risk, the file could be made readable for persons for whom it is not intended. Preservation of owner, group, and read/write permissions is only supported on Unix. +To check if dos2unix has support for preserving the user and group ownership of +files type C<dos2unix -V>. + +Conversion is always done via a temporary file. When an error occurs halfway +the conversion, the temporary file is deleted and the original file stays +intact. When the conversion is successful, the original file is replaced with +the temporary file. You may have write permission on the original file, but no +permission to put the same user and/or group ownership properties on the +temporary file as the original file has. This means you are not able to +preserve the user and/or group ownership of the original file. In this case you +can use option C<--allow-chown> to continue with the conversion: + + dos2unix --allow-chown foo.txt + +Another option is to use new file mode: + + dos2unix -n foo.txt foo.txt + +The advantage of the C<--allow-chown> option is that you can use wildcards, +and the ownership properties will be preserved when possible. + =item B<-q, --quiet> Quiet mode. Suppress all warnings and messages. The return value is zero. |