Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Jun 2020 19:11:36 +0000 (UTC)
From:      Dan Langille <dvl@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r540825 - in head/devel: . py-ttictoc
Message-ID:  <202006291911.05TJBam3044453@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dvl
Date: Mon Jun 29 19:11:36 2020
New Revision: 540825
URL: https://svnweb.freebsd.org/changeset/ports/540825

Log:
  Add py-ttictoc
  
  Tools for timing python code.
  
  PR:		247354
  Submitted by:	Gilbert Morgan <gmm@tutanota.com>

Added:
  head/devel/py-ttictoc/
  head/devel/py-ttictoc/Makefile   (contents, props changed)
  head/devel/py-ttictoc/distinfo   (contents, props changed)
  head/devel/py-ttictoc/pkg-descr   (contents, props changed)
Modified:
  head/devel/Makefile

Modified: head/devel/Makefile
==============================================================================
--- head/devel/Makefile	Mon Jun 29 19:03:39 2020	(r540824)
+++ head/devel/Makefile	Mon Jun 29 19:11:36 2020	(r540825)
@@ -5146,6 +5146,7 @@
     SUBDIR += py-tree-format
     SUBDIR += py-trimesh
     SUBDIR += py-trollius
+    SUBDIR += py-ttictoc
     SUBDIR += py-ttystatus
     SUBDIR += py-tvrage
     SUBDIR += py-tw.forms

Added: head/devel/py-ttictoc/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/py-ttictoc/Makefile	Mon Jun 29 19:11:36 2020	(r540825)
@@ -0,0 +1,22 @@
+# $FreeBSD$
+
+PORTNAME=	ttictoc
+PORTVERSION=	0.5.6
+CATEGORIES=	devel
+MASTER_SITES=	CHEESESHOP
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	gmm@tutanota.com
+COMMENT=	Time execution of blocks of code
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+RUN_DEPENDS+=	${PYTHON_PKGNAMEPREFIX}black>0:devel/py-black@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}pytest>0:devel/py-pytest@${PY_FLAVOR} \
+		${PYTHON_PKGNAMEPREFIX}flake8>0:devel/py-flake8@${PY_FLAVOR}
+
+USES=	localbase python
+USE_PYTHON=	autoplist distutils
+
+.include <bsd.port.mk>

Added: head/devel/py-ttictoc/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/py-ttictoc/distinfo	Mon Jun 29 19:11:36 2020	(r540825)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1592422035
+SHA256 (ttictoc-0.5.6.tar.gz) = 9ae0a534faf299b13f7d71693f8f97b28069932e2583effec799b7e8bf1964d9
+SIZE (ttictoc-0.5.6.tar.gz) = 4385

Added: head/devel/py-ttictoc/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/devel/py-ttictoc/pkg-descr	Mon Jun 29 19:11:36 2020	(r540825)
@@ -0,0 +1,14 @@
+Time execution of blocks of code.
+
+Tested against python 3.6+, but should work with other versions.
+
+The easiest way to time something is with tic and toc:
+
+import time
+from ttictoc import tic,toc
+tic()
+time.sleep(1)
+elapsed = toc()
+print('Elapsed time:',elapsed)
+
+WWW: https://github.com/hector-sab/ttictoc



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202006291911.05TJBam3044453>