From debbugs-submit-bounces@debbugs.gnu.org Wed Sep 18 12:05:59 2013 Received: (at submit) by debbugs.gnu.org; 18 Sep 2013 16:05:59 +0000 Received: from localhost ([127.0.0.1]:46928 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VMKGN-00071L-5S for submit@debbugs.gnu.org; Wed, 18 Sep 2013 12:05:59 -0400 Received: from eggs.gnu.org ([208.118.235.92]:33064) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VMHTh-0002SF-Cu for submit@debbugs.gnu.org; Wed, 18 Sep 2013 09:07:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VMHTZ-00068I-Nk for submit@debbugs.gnu.org; Wed, 18 Sep 2013 09:07:27 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=BAYES_20,FREEMAIL_FROM, HTML_MESSAGE,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:34756) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMHTZ-000684-JZ for submit@debbugs.gnu.org; Wed, 18 Sep 2013 09:07:25 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34770) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMHTY-0003Sd-BW for bug-coreutils@gnu.org; Wed, 18 Sep 2013 09:07:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VMHTX-00067W-Ax for bug-coreutils@gnu.org; Wed, 18 Sep 2013 09:07:24 -0400 Received: from mail-ob0-x236.google.com ([2607:f8b0:4003:c01::236]:40063) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VMHTX-00067H-5U for bug-coreutils@gnu.org; Wed, 18 Sep 2013 09:07:23 -0400 Received: by mail-ob0-f182.google.com with SMTP id wo20so7561103obc.27 for ; Wed, 18 Sep 2013 06:07:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=7IcgtxcOsxrkUxjV23dYBAbP4S4UpjDIt3eQGdczaHI=; b=gCl06N1C1SpLKTSubJ+6SaVCOifwQUUatocDvcDbdPQc8Ugt7xieVWrIRlTyDUKqB7 E4gFRdyL/1emhfaal6CucZqPC+AZACd2PrI+SIO6FSqEH6BMIP37ct5zcid7Z6MpUP/5 0F7/INs/Bgfy9Wwx/ANW2zSp6xoJEV+fGiijJmDnmhIgY9KsP5zIBBgdrEaU+NuXXlD3 vkYPEo7hkIh1Urd4CHnO1Ip6Ql9qQgzUpxkkvhDXD/KUlC21QQXURQn7yaAxQ96XXow1 zoOa7/t+nvrNmjCmsQYbt3K4XorHRxXQ7qvNbAR1r2uHo7khVGhpYqivzodw/bvzplpu c0Qg== MIME-Version: 1.0 X-Received: by 10.182.246.74 with SMTP id xu10mr1336874obc.23.1379509642411; Wed, 18 Sep 2013 06:07:22 -0700 (PDT) Received: by 10.60.28.74 with HTTP; Wed, 18 Sep 2013 06:07:22 -0700 (PDT) Date: Wed, 18 Sep 2013 14:07:22 +0100 Message-ID: Subject: bug report From: =?ISO-8859-1?Q?Jo=E3o_Marques?= To: bug-coreutils@gnu.org Content-Type: multipart/alternative; boundary=001a11c2e608338e1e04e6a81e10 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -4.0 (----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Wed, 18 Sep 2013 12:05:57 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -4.0 (----) --001a11c2e608338e1e04e6a81e10 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi good afternoon Yesterday i was reading the manual (man date) of the date command and I think that the option + and ' isn't refer on it so i was trying to make this command on a script: $(date +'%Y-%m-%d '%H:%M:%S') maybe I'm wrong but if not, it was nice to include this information an some examples on the manual so that anyone could make it more easily. Best regards Jo=E3o Marques --001a11c2e608338e1e04e6a81e10 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable
Hi good afternoon

Yesterday i was reading the manual (man date) of the date command and I= think that the option + and ' isn't refer on it

so i= was trying to make this command on a script:

=A0$(date +'%Y-%m-%d '%H:%M:%S')=A0

maybe I&#= 39;m wrong but if not, it was nice to include this information an some exam= ples on the=A0 manual
so that anyone could make it more easily.
Best regards
Jo=E3o Marques
--001a11c2e608338e1e04e6a81e10-- From debbugs-submit-bounces@debbugs.gnu.org Wed Sep 18 12:25:44 2013 Received: (at control) by debbugs.gnu.org; 18 Sep 2013 16:25:44 +0000 Received: from localhost ([127.0.0.1]:47024 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VMKZS-0007aJ-GM for submit@debbugs.gnu.org; Wed, 18 Sep 2013 12:25:42 -0400 Received: from mx1.redhat.com ([209.132.183.28]:29276) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VMKZO-0007a1-3X; Wed, 18 Sep 2013 12:25:38 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r8IGPbh3006871 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 18 Sep 2013 12:25:37 -0400 Received: from [10.3.113.10] ([10.3.113.10]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r8IGPau7031574; Wed, 18 Sep 2013 12:25:36 -0400 Message-ID: <5239D400.20806@redhat.com> Date: Wed, 18 Sep 2013 10:25:36 -0600 From: Eric Blake Organization: Red Hat, Inc. User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130805 Thunderbird/17.0.8 MIME-Version: 1.0 To: =?UTF-8?B?Sm/Do28gTWFycXVlcw==?= Subject: Re: bug#15407: bug report References: In-Reply-To: X-Enigmail-Version: 1.5.2 OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="gkBgx0KjV9DtUcCXBJ1xmUJ5BNchd75UH" X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Spam-Score: -5.7 (-----) X-Debbugs-Envelope-To: control Cc: 15407-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.7 (-----) This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --gkBgx0KjV9DtUcCXBJ1xmUJ5BNchd75UH Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable tag 15407 notabug thanks On 09/18/2013 07:07 AM, Jo=C3=A3o Marques wrote: > Hi good afternoon >=20 > Yesterday i was reading the manual (man date) of the date command and I= > think that the option + and ' isn't refer on it >=20 > so i was trying to make this command on a script: >=20 > $(date +'%Y-%m-%d '%H:%M:%S') As written, that's not a valid command, because it has unbalanced quotes. ' is not an option character seen by date, but a quoting metacharacter consumed by the shell. You may want to read a good manual on shell quoting; but as a short tutorial, all of the following are equivalent: date +%y-%m-%d\ %H:%M:%S date '+%y-%m-%d %H:%M:%S' date '+'"%y-%m-%d"' '"%H:%M:%S" and so on. To see what the shell actually did with your quote characters, use echo (and since the output of all three of these commands is identical, you can understand why I claim that ' is not a format character recognized by date): echo date +%y-%m-%d\ %H:%M:%S echo date '+%y-%m-%d %H:%M:%S' echo date '+'"%y-%m-%d"' '"%H:%M:%S" Why some people insist on using '' around most of the FORMAT argument, but not the leading + portion (that is, why you see +'%y...' instead of '+%y...' in examples), is beyond me, but it is perfectly valid shell quoting either way. >=20 > maybe I'm wrong but if not, it was nice to include this information an = some > examples on the manual > so that anyone could make it more easily. Meanwhile, the '+' option IS documented, in both the man and info pages. The man page starts out with: SYNOPSIS date [OPTION]... [+FORMAT] date [-u|--utc|--universal] [MMDDhhmm[[CC]YY][.ss]] See, right there, the leading '+' is what designates a FORMAT argument. Failing to use a leading '+' is what tells date to interpret its argument as MMDDhhmm instead of FORMAT. Therefore, I'm closing this as not a bug, although you should feel free to reply with any further questions. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --gkBgx0KjV9DtUcCXBJ1xmUJ5BNchd75UH Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.14 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJSOdQAAAoJEKeha0olJ0Nq4UMH/2pOm47JUtLDZelKTLZoIiCT QCXl8RF60DqU6mL0w20kRNvasQRyyoaCo45WBo1e0nwgCmCicnj+hOUX9kSlWNms aMWj4om7h9CmVK2B/x1XMbH2A8dnrgOBazdEioo+fVUC6GuBL3UK8jkPmlrsn9A4 IyFk3Sl6B6oKmGHL4zY7MGXmfvip08N0Z06n6mHyRuOIF7gD1cwKmR1zgalZ49Y6 GplaGgROzegjYZgyYoEK2lD+WIywHAKey+VBI8cYyHUAVuZIjxMBsp1yoGlzSFcd TPu/aF0gA1TxVZEoFHVduuWmNKqwTouyEJ1MkiRicWieIkBhN00ZyEuvxmFFctM= =4kZE -----END PGP SIGNATURE----- --gkBgx0KjV9DtUcCXBJ1xmUJ5BNchd75UH-- From unknown Sat Jun 21 10:40:10 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 17 Oct 2013 11:24:03 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator