From owner-cvs-all@FreeBSD.ORG Mon Aug 9 13:43:39 2004 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 780D216A4CE; Mon, 9 Aug 2004 13:43:39 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6E57143D48; Mon, 9 Aug 2004 13:43:39 +0000 (GMT) (envelope-from yar@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i79DhdMr059618; Mon, 9 Aug 2004 13:43:39 GMT (envelope-from yar@repoman.freebsd.org) Received: (from yar@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i79DhdP8059617; Mon, 9 Aug 2004 13:43:39 GMT (envelope-from yar) Message-Id: <200408091343.i79DhdP8059617@repoman.freebsd.org> From: Yar Tikhiy Date: Mon, 9 Aug 2004 13:43:39 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/bin/date date.1 vary.c X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 09 Aug 2004 13:43:39 -0000 yar 2004-08-09 13:43:39 UTC FreeBSD src repository Modified files: bin/date date.1 vary.c Log: Change the behaviour of `-v' so that, e.g., stepping a month back on March 31 won't take you to March 2 or 3 (now the result will be the last day of February.) In general, now stepping by months from the last days of the current month A will take you to the very last day of the target month B if B is shorter than A. The previous version would just step to March 31 and rely on mktime(3) to correct the date. Despite its simplicity, such way was counter-intuitive to users and caused pain to shell script writers. Noticed by: Igor Timkin Approved by: brian MFC after: 2 weeks Revision Changes Path 1.68 +23 -1 src/bin/date/date.1 1.16 +7 -0 src/bin/date/vary.c