summaryrefslogtreecommitdiff
path: root/misc/tools/download-count.py
diff options
context:
space:
mode:
authorRasmus Andersson <rasmus@notion.se>2018-09-03 22:55:49 +0300
committerRasmus Andersson <rasmus@notion.se>2018-09-03 22:55:49 +0300
commitc833e252c925e8dd68108660710ca835d95daa6f (patch)
tree6b2e28264ed45efd7f054e453b622098d0d875b8 /misc/tools/download-count.py
parent8c1a4c181ef12000179dfec541f1af87e9b03122 (diff)
downloadinter-c833e252c925e8dd68108660710ca835d95daa6f.tar.xz
Major overhaul, moving from UFO2 to Glyphs and UFO3, plus a brand new and much simpler fontbuild
Diffstat (limited to 'misc/tools/download-count.py')
-rwxr-xr-xmisc/tools/download-count.py19
1 files changed, 19 insertions, 0 deletions
diff --git a/misc/tools/download-count.py b/misc/tools/download-count.py
new file mode 100755
index 000000000..c70532490
--- /dev/null
+++ b/misc/tools/download-count.py
@@ -0,0 +1,19 @@
+#!/usr/bin/env python
+# encoding: utf8
+from __future__ import print_function
+import os, sys, json, urllib2
+
+f = urllib2.urlopen('https://api.github.com/repos/rsms/inter/releases')
+releases = json.load(f)
+
+countTotal = 0
+
+for release in releases:
+ if len(release['assets']) > 0:
+ count = release['assets'][0]['download_count']
+ countTotal += count
+ print('%s: %d' % (release['tag_name'], count))
+ else:
+ print('%s: (missing)' % release['tag_name'])
+
+print('Total: %d' % countTotal)