Cant download iso8601 compliant files to windows






















July How can I do it? Improve this question. Peter Mortensen See: techontip. Get-Date -Format o — Mathias R. Add a comment. Active Oldest Votes. Like so, Get-Date -Format "o" T Improve this answer. Despite of the possible portability problem, I like this solution because it is simple and you can basically memorize it for your quickly-written scripts. You can reuse it: Get-Date Get-Date. Mathias R. Jessen Mathias R. Jessen k 8 8 gold badges silver badges bronze badges.

This should be the correct answer, since the question was framed in a way that suggests portability is important. This will give you a timestamp in the local timezone! The "Z" suffix may be incorrect. I just tried in WPS 5. Show 1 more comment. The following works both in Windows PowerShell 5. Sign up or log in Sign up using Google.

Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Who owns this outage? Simple module to parse ISO dates. Navigation Project description Release history Download files. Project links Homepage Documentation Repository. Maintainers mick. Times hh:mm:ss. Days and months without a leading 0 2 vs 02 will be parsed. If time zone information is omitted the default time zone given is used which in turn defaults to UTC.

Use a default of None to yield naive datetime instances. Testing poetry install poetry run nox Note that you need all the pythons installed to perform a tox run see below. Alternatively, to test only with your current python: poetry install pytest.

Note new and previous version. Supported Python Versions Tested against: Python 3. Changes 1. Remove python 2. Add PyPy 3 to tox test config. In particular more invalid cases are treated as errors. Also includes fixes for tests which is how these invalid cases got in in the first place.

The setup. Strictly speaking that was wrong but this is potentially backwards incompatible. Fixes issue Fixes issue 9. Addresses issue 7. Be a little more flexible when dealing with dates without leading zeroes. This violates the spec a little, but handles more dates as seen in the field. Addresses issue 6. If no default is specified then UTC is used. Addresses issue 4.

Project details Project links Homepage Documentation Repository. Download files Download the file for your platform. Files for iso, version 1. Close Hashes for iso File type Wheel. Python version py3.



0コメント

  • 1000 / 1000