{"thread":{"id":"53290","subject":"[BUG REPORT] --date argument doesn't validate dates","startedAt":"2020-04-22T21:02:54Z","lastAt":"2020-04-22T21:27:11Z","messageCount":2,"participants":["Yuri","brian m. carlson"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"395947","messageId":"d633919a-99a4-0b90-f355-66a17000f83f@rawbw.com","threadId":"53290","inReplyTo":null,"subject":"[BUG REPORT] --date argument doesn't validate dates","fromName":"Yuri","fromEmail":"yuri@rawbw.com","sentAt":"2020-04-22T20:40:48Z","receivedAt":"2020-04-22T21:02:54Z","isPatch":false,"sender":{"key":"yuri@rawbw.com","avatar":null},"body":"For example, the following command accepts an invalid month \"Dx\" and an \ninvalid year \"20221\" and sets the month to \"Apr\" and the year to \"2020\".\n\n\nYuri\n\n\n\n$ git commit --amend --no-edit --date \"Mon 20 Dx 20221 20:19:19 PST\"\n[master 668e255] Initial\n  Date: Mon Apr 20 20:19:19 2020 -0700\n  1 file changed, 1 insertion(+)\n  create mode 100644 File\n[yuri@yv /usr/home/yuri/github/git-date]$ git log\ncommit 668e255b54d08ed898e6d44f19954b2116d5a56c (HEAD -> master)\nAuthor: Yuri <yuri@rawbw.com>\nDate:   Mon Apr 20 20:19:19 2020 -0700\n\n     Initial\n\n"},{"id":"395949","messageId":"20200422212633.GI6465@camp.crustytoothpaste.net","threadId":"53290","inReplyTo":"d633919a-99a4-0b90-f355-66a17000f83f@rawbw.com","subject":"Re: [BUG REPORT] --date argument doesn't validate dates","fromName":"brian m. carlson","fromEmail":"sandals@crustytoothpaste.net","sentAt":"2020-04-22T21:26:33Z","receivedAt":"2020-04-22T21:27:11Z","isPatch":false,"sender":{"key":"sandals@crustytoothpaste.net","avatar":"https://avatars.githubusercontent.com/u/497054?v=4"},"body":"On 2020-04-22 at 20:40:48, Yuri wrote:\n> For example, the following command accepts an invalid month \"Dx\" and an\n> invalid year \"20221\" and sets the month to \"Apr\" and the year to \"2020\".\n\nThe --date argument accepts a wide variety of formats, including some\nformally specified ones, as well generalized handling through the\n\"approxidate\" approach.  So it's designed to operate on formats that are\nnot well understood and do the best it can with them.  This also allows\nit do things like ignore the irrelevant word \"ago\" in \"5 days ago\" and\nstill do the right thing.\n\nIf you want to be sure that your date is uniformly understood, then the\nbest approach is to either use the Git internal format or RFC 3339\n(which is a profile of ISO 8601).\n-- \nbrian m. carlson: Houston, Texas, US\nOpenPGP: https://keybase.io/bk2204\n"}]}