From 27e898fbe5ef8b19dad1b9e1415b5cdac55650cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20P=C3=A9ters?= Date: Fri, 23 Aug 2019 09:44:32 +0200 Subject: [PATCH] sassw: include time taken for rebuilding css --- bin/sassw | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bin/sassw b/bin/sassw index acf3692..56ecdef 100755 --- a/bin/sassw +++ b/bin/sassw @@ -11,6 +11,7 @@ import os import pyinotify import subprocess import sys +import time filename = sys.argv[1] @@ -26,8 +27,10 @@ class EventManager(pyinotify.ProcessEvent): if event.pathname in sources: filename = os.path.basename(event.pathname) print(f'{filename} changed, building', end='') + t0 = time.time() build() - print('.') + elapsed_time = time.time() - t0 + print(' (%.2fs)' % (time.time() - t0)) build() wm = pyinotify.WatchManager()