From nobody Sun Jan 02 02:15:40 2022 X-Original-To: bugs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id CAE9F192C48E for ; Sun, 2 Jan 2022 02:15:41 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4JRMt51JPCz4V0T for ; Sun, 2 Jan 2022 02:15:41 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0D92F1D81 for ; Sun, 2 Jan 2022 02:15:41 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 2022FedH060567 for ; Sun, 2 Jan 2022 02:15:40 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 2022Fe0l060566 for bugs@FreeBSD.org; Sun, 2 Jan 2022 02:15:40 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 260871] [patch] /usr/bin/touch enhancement Date: Sun, 02 Jan 2022 02:15:40 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: bin X-Bugzilla-Version: Unspecified X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: jamie@catflap.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1641089741; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=lGl8fI0ssiWMZF+y3kDc5yl/oINxTM4HhLajDhhpwqA=; b=kKhalhH1FT/u3aISJHKCgb8R5vU/VzAygxsqP4t/imZ2dH1l9gbhlHKX7YnbcQzT9XEH+J pgdZuNxHP5FleUBvaC9tuZYduNPcbLeJjTRqOUTFoNZ56UC625qpi9h3YIzQjWQBolP2dJ G7DgtfekKoEXN1CE+4taYY/y0cyWdY7wF5HTHLJ1wdysFSeFnHpoq7y1ovPPXBUm3NLPZQ hQUTe4Tv+vj0KJmVmzmuiIF20EK+2BHznZoMXpm47ySs9se/FdCQlSXLOHr0hlOdW44ccf UXP2KE83ikmJuP/sUixEN0Rp86r/4R4mkrgMquUbWX3ze5ciiJsGWSRxmjyWDw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1641089741; a=rsa-sha256; cv=none; b=f9wItYEyokNxoeE5XaZIm838dvwBYkWNeXiLd9KqTyr9jVL9RtLRK5CWV9AMQO7EF12mWT StfBytlkbpYnOhecPiwNRlhF+zeVFQjG1gGXQoky1N//C9vxyxJfNEBTCbXlF6xfnWRAOy q122NUGZsyjzKpP69AsLH9CnLUjMg8V8AJqJK1gBPFWuzkVtmw47HY4FgCNqn8asjqD4ae ux8xOknhfsiLtwm6XCKvTf+R3gcwJrvfy473Scsf7jrCLP/3HwHI5luf3Wa0sbVHZcTSbp /X+vPznqyHn+g8zNlHeVnt8B/ekJe4RGFBz2T9z5dE0qHV8+nmp0ugiKm+Npaw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D260871 Bug ID: 260871 Summary: [patch] /usr/bin/touch enhancement Product: Base System Version: Unspecified Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: jamie@catflap.org Created attachment 230614 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D230614&action= =3Dedit patch to add "-R" to touch(1) I'm not quite sure how you deal with "non-standard" additions to standard commands, so please be gentle! Incidentally, I have no preference for actual implementation, this is just = what I've been using for a while. Comments welcome! Basically, touch(1) has: -h If the file is a symbolic link, change the times of the link itself rather than the file that the link points to. and: -r Use the access and modifications times from the specified file ins= tead of the current time of day. If "-r" points to a link, the link is always followed to retrieve the datet= ime information. I have a program that needs to "-r" the datetime of the link itself if the = file is a link. Up to now, I've been doing a stat of the file, and then forming the date to add, but recently thought to add this option: -R As -r , but if the file is a symbolic link, return the times of the link itself rather than the file that the link points to. Patch attached. Comments? --=20 You are receiving this mail because: You are the assignee for the bug.=