aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/time.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/time.scm')
-rw-r--r--gnu/packages/time.scm71
1 files changed, 52 insertions, 19 deletions
diff --git a/gnu/packages/time.scm b/gnu/packages/time.scm
index 746ba97c0f..d6ebb59a1e 100644
--- a/gnu/packages/time.scm
+++ b/gnu/packages/time.scm
@@ -18,6 +18,7 @@
;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
;;; Copyright © 2020 Lars-Dominik Braun <ldb@leibniz-psychology.org>
;;; Copyright © 2020 Tanguy Le Carrour <tanguy@bioneland.org>
+;;; Copyright © 2021 Ryan Prior <rprior@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -35,18 +36,22 @@
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages time)
- #:use-module (guix licenses)
- #:use-module (guix packages)
- #:use-module (guix download)
- #:use-module (guix git-download)
- #:use-module (guix build-system gnu)
- #:use-module (guix build-system python)
- #:use-module (gnu packages)
#:use-module (gnu packages check)
#:use-module (gnu packages compression)
+ #:use-module (gnu packages golang)
#:use-module (gnu packages perl)
#:use-module (gnu packages python)
- #:use-module (gnu packages python-xyz))
+ #:use-module (gnu packages python-xyz)
+ #:use-module (gnu packages terminals)
+ #:use-module (gnu packages textutils)
+ #:use-module (gnu packages)
+ #:use-module (guix build-system gnu)
+ #:use-module (guix build-system go)
+ #:use-module (guix build-system python)
+ #:use-module (guix download)
+ #:use-module (guix git-download)
+ #:use-module (guix licenses)
+ #:use-module (guix packages))
(define-public time
(package
@@ -92,14 +97,14 @@ expressions.")
(define-public python-pytzdata
(package
(name "python-pytzdata")
- (version "2019.3")
+ (version "2020.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "pytzdata" version))
(sha256
(base32
- "0ppfc6kz4p41mxyqxq1g1zp6gvns99g6b344qj6ih0x9vxy6zh7s"))))
+ "0h0md0ldhb8ghlwjslkzh3wcj4fxg3n43bj5sghqs2m06nri7yiy"))))
(build-system python-build-system)
;; XXX: The PyPI distribution contains no tests, and the upstream
;; repository lacks a setup.py! How to build from git?
@@ -118,14 +123,15 @@ expressions.")
(define-public python-pytz
(package
(name "python-pytz")
- (version "2020.4")
+ ;; This package should be kept in sync with tzdata in (gnu packages base).
+ (version "2021.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "pytz" version))
(sha256
(base32
- "0s72lz9q7rm2xgl2in0nvhn5cp0cyrxa257fpj2919g0s797ssry"))))
+ "1nn459q7zg20n75akxl3ljkykgw1ydc8nb05rx1y4f5zjh4ak943"))))
(build-system python-build-system)
(home-page "http://pythonhosted.org/pytz")
(synopsis "Python timezone library")
@@ -269,14 +275,14 @@ Python datetime objects.")
(define-public python-tzlocal
(package
(name "python-tzlocal")
- (version "1.5.1")
+ (version "2.1")
(source
(origin
(method url-fetch)
(uri (pypi-uri "tzlocal" version))
(sha256
(base32
- "0kiciwiqx0bv0fbc913idxibc4ygg4cb7f8rcpd9ij2shi4bigjf"))))
+ "0i1fm4sl04y65qnaqki0w75j34w863gxjj8ag0vwgvaa572rfg34"))))
(build-system python-build-system)
(arguments
`(#:phases
@@ -284,9 +290,12 @@ Python datetime objects.")
(add-before 'check 'fix-symlink-test
;; see: https://github.com/regebro/tzlocal/issues/53
(lambda _
- (delete-file "tzlocal/test_data/symlink_localtime/etc/localtime")
+ (delete-file "tests/test_data/symlink_localtime/etc/localtime")
(symlink "../usr/share/zoneinfo/Africa/Harare"
- "tzlocal/test_data/symlink_localtime/etc/localtime")
+ "tests/test_data/symlink_localtime/etc/localtime")
+ ;; And skip the test_fail test, it is known to fail
+ (substitute* "tests/tests.py"
+ (("def test_fail") "def _test_fail"))
#t)))))
(propagated-inputs
`(("python-pytz" ,python-pytz)))
@@ -440,9 +449,6 @@ converting dates, times, and timestamps. It implements and updates the
datetime type.")
(license asl2.0)))
-(define-public python2-arrow
- (package-with-python2 python-arrow))
-
(define-public python-aniso8601
(package
(name "python-aniso8601")
@@ -507,3 +513,30 @@ datetime type.")
modifies the @code{time}, @code{gettimeofday} and @code{clock_gettime} system
calls.")
(license gpl2)))
+
+(define-public countdown
+ (package
+ (name "countdown")
+ (version "1.0.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/antonmedv/countdown")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0pdaw1krr0bsl4amhwx03v2b02iznvwvqn7af5zp4fkzjaj14cdw"))))
+ (build-system go-build-system)
+ (arguments
+ '(#:import-path "github.com/antonmedv/countdown"))
+ (native-inputs
+ `(("runewidth" ,go-github.com-mattn-go-runewidth)
+ ("termbox" ,go-github.com-nsf-termbox-go)))
+ (home-page "https://github.com/antonmedv/countdown")
+ (synopsis "Counts to zero with a text user interface")
+ (description
+ "Countdown provides a fancy text display while it counts down to zero
+from a starting point you provide. The user can pause and resume the
+countdown from the text user interface.")
+ (license expat)))