[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#27942: Bug regarding "touch" command

From: Paul Eggert
Subject: bug#27942: Bug regarding "touch" command
Date: Fri, 4 Aug 2017 00:16:23 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

pavan kumar yalavarthi wrote:
" *touch  -* " is not working i.e., file named " - " is not being created
using *touch *command in* ubuntu* flavours  , but working fine with* linux *

It's not a bug. In coreutils, 'touch -' is documented to touch the standard output file, not a file named '-'. The POSIX specification for 'touch' allows either the coreutils behavior or the other behavior that you mentioned. If you want to touch a file named '-', the command 'touch ./-' is a portable way to do it.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]