From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3209 invoked by alias); 25 Jun 2015 01:08:20 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 35595 Received: (qmail 26837 invoked from network); 25 Jun 2015 01:08:17 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.0 Message-ID: <558B5342.2090706@inlv.org> Date: Thu, 25 Jun 2015 03:02:58 +0200 From: Martijn Dekker User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: zsh-workers@zsh.org Subject: '>>' does not create file if set -C (noclobber) is active Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit If the 'noclobber' option (set -C) is active, the append ('>>') output redirection will not create a file if it doesn't exist. % set -C % echo hi >> blah zsh: no such file or directory: blah POSIX: http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_07_03 "If the file does not exist, it shall be created." It does not mention that the noclobber option should influence this. By definition, a file that doesn't exist cannot be clobbered, so it seems to me that logically this shell option shouldn't apply. bash, (d)ash, ksh93, mksh, and yash all act like POSIX says. I have no opinion on whether this should be an overall fix or a fix for the emulation modes. Thanks, - Martijn