]> git.phdru.name Git - xsetbg.git/blobdiff - find_oldest.py
Display stats
[xsetbg.git] / find_oldest.py
diff --git a/find_oldest.py b/find_oldest.py
deleted file mode 100755 (executable)
index 9b94817..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-#! /usr/bin/env python
-"""Count all and shown files; display the date of oldest file
-
-This file is a part of XSetBg.
-
-"""
-
-__author__ = "Oleg Broytman <phd@phdru.name>"
-__copyright__ = "Copyright (C) 2006-2015 PhiloSoft Design"
-__license__ = "GNU GPL"
-
-import sys
-from time import localtime, asctime
-from xsetbg_db import xsetbg_db
-
-if not xsetbg_db:
-    sys.exit("Error: no database found")
-
-print "Total files:", xsetbg_db.select().count()
-print "Shown files:", xsetbg_db.select('last_shown IS NOT NULL').count()
-last_shown = xsetbg_db.select('last_shown IS NOT NULL',
-                              orderBy='last_shown')[0].last_shown
-print "Oldest:", asctime(localtime(last_shown))