1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2013, 2017 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
5 ;;; Copyright © 2015, 2016, 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
6 ;;; Copyright © 2015, 2017 Leo Famulari <leo@famulari.name>
7 ;;; Copyright © 2015, 2017 Cyril Roelandt <tipecaml@gmail.com>
8 ;;; Copyright © 2016 Sou Bunnbu <iyzsong@gmail.com>
9 ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
10 ;;; Copyright © 2016 Danny Milosavljevic <dannym+a@scratchpost.org>
11 ;;; Copyright © 2016 Marius Bakke <mbakke@fastmail.com>
12 ;;; Copyright © 2016, 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
13 ;;; Copyright © 2017 Ben Woodcroft <donttrustben@gmail.com>
14 ;;; Copyright © 2017 Nils Gillmann <ng0@n0.is>
15 ;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu>
16 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
18 ;;; This file is part of GNU Guix.
20 ;;; GNU Guix is free software; you can redistribute it and/or modify it
21 ;;; under the terms of the GNU General Public License as published by
22 ;;; the Free Software Foundation; either version 3 of the License, or (at
23 ;;; your option) any later version.
25 ;;; GNU Guix is distributed in the hope that it will be useful, but
26 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
27 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
28 ;;; GNU General Public License for more details.
30 ;;; You should have received a copy of the GNU General Public License
31 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
33 (define-module (gnu packages time)
34 #:use-module (guix licenses)
35 #:use-module (guix packages)
36 #:use-module (guix download)
37 #:use-module (guix build-system gnu)
38 #:use-module (guix build-system python)
39 #:use-module (gnu packages check)
40 #:use-module (gnu packages compression)
41 #:use-module (gnu packages python))
50 (uri (string-append "mirror://gnu/time/time-"
54 "07jj7cz6lc13iqrpgn81ivqh8rkm73p4rnivwgrrshk23v4g1b7v"))))
55 (build-system gnu-build-system)
56 (home-page "https://www.gnu.org/software/time/")
57 (synopsis "Run a command, then display its resource usage")
59 "Time is a command that displays information about the resources that a
60 program uses. The display output of the program can be customized or saved
64 (define-public python-pytzdata
66 (name "python-pytzdata")
71 (uri (pypi-uri "pytzdata" version))
74 "1wi3jh39zsa9iiyyhynhj7w5b2p9wdyd0ppavpsrmf3wxvr7cwz8"))))
75 (build-system python-build-system)
77 `(("python-pytest" ,python-pytest)
78 ("python-nose" ,python-nose)))
79 (home-page "https://github.com/sdispater/pytzdata")
80 (synopsis "Timezone database for Python")
82 "This library provides a timezone database for Python.")
85 (define-public python2-tzdata
86 (package-with-python2 python-pytzdata))
88 (define-public python-pytz
95 (uri (pypi-uri "pytz" version ".zip"))
98 "1dw5l527vcafvdqq4wadwl7ikhb2sssz0v0cssibh8890kyczr7s"))))
99 (build-system python-build-system)
102 (home-page "http://pythonhosted.org/pytz")
103 (synopsis "Python timezone library")
104 (description "This library brings the Olson tz database into Python. It
105 allows accurate and cross platform timezone calculations using Python 2.4 or
106 higher. It also solves the issue of ambiguous times at the end of daylight
107 saving time. Almost all of the Olson timezones are supported.")
110 (define-public python2-pytz
111 (package-with-python2 python-pytz))
113 (define-public python-pendulum
115 (name "python-pendulum")
120 (uri (pypi-uri "pendulum" version))
123 "1fj36yxi2f4lzchzd8ny1qjl67dbypnk0gn8qwad2w78579m8m8z"))))
124 (build-system python-build-system)
126 `(("python-pytest" ,python-pytest)
127 ("python-nose" ,python-nose)))
129 `(("python-dateutil" ,python-dateutil)
130 ("python-pytzdata" ,python-pytzdata)
131 ("python-tzlocal" ,python-tzlocal)))
132 (home-page "https://github.com/sdispater/pendulum")
133 (synopsis "Alternate API for Python datetimes")
134 (description "Pendulum is a drop-in replacement for the standard
135 @{datetime} class, providing an alternative API. As it inherits from the
136 standard @code{datetime} all @code{datetime} instances can be replaced by
137 Pendulum instances.")
140 (define-public python2-pendulum
141 (package-with-python2 python-pendulum))
143 (define-public python-dateutil
145 (name "python-dateutil")
150 (uri (pypi-uri "python-dateutil" version))
153 "1jkahssf0ir5ssxc3ydbp8cpv77limn8d4s77szb2nrgl2r3h749"))))
154 (build-system python-build-system)
156 `(("python-six" ,python-six)))
157 (home-page "https://dateutil.readthedocs.io/en/stable/")
158 (synopsis "Extensions to the standard datetime module")
160 "The dateutil module provides powerful extensions to the standard
161 datetime module, available in Python 2.3+.")
164 (define-public python2-dateutil
165 (package-with-python2 python-dateutil))
167 (define-public python-parsedatetime
169 (name "python-parsedatetime")
174 (uri (pypi-uri "parsedatetime" version))
177 "0jxqkjks7z9dn222cqgvskp4wr6d92aglinxq7pd2w4mzdc7r09x"))))
178 (build-system python-build-system)
180 `(("python-nose" ,python-nose)
181 ("python-pyicu" ,python-pyicu)
182 ("python-pytest" ,python-pytest)
183 ("python-pytest-runner" ,python-pytest-runner)))
185 `(("python-future" ,python-future)))
186 (home-page "https://github.com/bear/parsedatetime/")
187 (synopsis "Parse human-readable date/time text")
189 "Parse human-readable date/time text.")
192 (define-public python2-parsedatetime
193 (package-with-python2 python-parsedatetime))
195 (define-public python-tzlocal
197 (name "python-tzlocal")
202 (uri (pypi-uri "tzlocal" version))
205 "0paj7vlsb0np8b5sp4bv64wxv7qk2piyp7xg29pkhdjwsbls9fnb"))))
206 (build-system python-build-system)
208 `(("python-pytz" ,python-pytz)))
209 (home-page "https://github.com/regebro/tzlocal")
210 (synopsis "Local timezone information for Python")
212 "Tzlocal returns a tzinfo object with the local timezone information.
213 This module attempts to fix a glaring hole in pytz, that there is no way to
214 get the local timezone information, unless you know the zoneinfo name, and
215 under several distributions that's hard or impossible to figure out.")
218 (define-public python-isodate
220 (name "python-isodate")
225 (uri (pypi-uri "isodate" version))
228 "0cafaiwixgpxwh9dsd28qb0dbzsj6xpxjdkyk30ns91ps10mq422"))))
229 (build-system python-build-system)
230 (home-page "http://cheeseshop.python.org/pypi/isodate")
231 (synopsis "Python date parser and formatter")
233 "Python-isodate is a python module for parsing and formatting
234 ISO 8601 dates, time and duration.")
237 (define-public python2-isodate
238 (package-with-python2 python-isodate))
240 (define-public python-iso8601
242 (name "python-iso8601")
247 (uri (pypi-uri "iso8601" version))
250 "0c7gh3lsdjds262h0v1sqc66l7hqgfwbakn96qrhdbl0i3vm5yz8"))))
251 (build-system python-build-system)
253 `(("python-pytest" ,python-pytest)))
254 (home-page "https://bitbucket.org/micktwomey/pyiso8601")
255 (synopsis "Module to parse ISO 8601 dates")
257 "This module parses the most common forms of ISO 8601 date strings (e.g.
258 @code{2007-01-14T20:34:22+00:00}) into @code{datetime} objects.")
261 (define-public python2-iso8601
262 (package-with-python2 python-iso8601))
264 (define-public python-monotonic
266 (name "python-monotonic")
271 (uri (pypi-uri "monotonic" version))
274 "1c6z46yb600klbfhqadyl7vq0jdjdxkm72k43ra3iw3d0xakv593"))))
275 (build-system python-build-system)
276 (arguments '(#:tests? #f)) ; no tests
277 (home-page "https://github.com/atdt/monotonic")
278 (synopsis "Implementation of time.monotonic() for Python 2 & < 3.3")
280 "This module provides a @code{monotonic()} function which returns the
281 value (in fractional seconds) of a clock which never goes backwards.")
284 (define-public python2-monotonic
285 (package-with-python2 python-monotonic))
287 (define-public python-pyrfc3339
289 (name "python-pyrfc3339")
294 (uri (pypi-uri "pyRFC3339" version))
297 "0dgm4l9y8jiax5cp6yxjd2i27cq8h33sh81n1wfbmnmqb32cdywd"))))
298 (build-system python-build-system)
300 `(("python-pytz" ,python-pytz)))
302 `(("python-nose" ,python-nose)))
303 (home-page "https://github.com/kurtraschke/pyRFC3339")
304 (synopsis "Python timestamp library")
305 (description "Python library for generating and parsing RFC 3339-compliant
309 (define-public python2-pyrfc3339
310 (package-with-python2 python-pyrfc3339))
312 (define-public python-arrow
314 (name "python-arrow")
318 (uri (pypi-uri "arrow" version))
321 "08n7q2l69hlainds1byd4lxhwrq7zsw7s640zkqc3bs5jkq0cnc0"))))
322 (build-system python-build-system)
325 ("python-chai" ,python-chai)
326 ("python-simplejson" ,python-simplejson)))
328 `(("python-dateutil" ,python-dateutil)))
329 (home-page "https://github.com/crsmithdev/arrow/")
330 (synopsis "Dates and times for Python")
332 "Arrow is a Python library to creating, manipulating, formatting and
333 converting dates, times, and timestamps. It implements and updates the
337 (define-public python2-arrow
338 (package-with-python2 python-arrow))
340 (define-public python-aniso8601
342 (name "python-aniso8601")
347 (uri (pypi-uri "aniso8601" version))
350 "1waj54iv3n3lw1fapbz8a93yjgrybgpc86wif5baxdh1arpj9df3"))))
351 (build-system python-build-system)
353 `(("python-dateutil" ,python-dateutil)))
354 (home-page "https://bitbucket.org/nielsenb/aniso8601")
355 (synopsis "Python library for parsing ISO 8601 strings")
357 "This package contains a library for parsing ISO 8601 datetime strings.")
360 (define-public python2-aniso8601
361 (package-with-python2 python-aniso8601))