summary refs log tree commit diff
path: root/languageupdater.py
diff options
context:
space:
mode:
authorClayton G. Hobbs <clay@lakeserv.net>2015-12-30 23:33:29 -0500
committerClayton G. Hobbs <clay@lakeserv.net>2015-12-30 23:33:29 -0500
commite19d76f0515b291f9c6994bfd0faccccf5b894aa (patch)
treedb29ef0dbecee06e0788d9f72c9d327caa1b1479 /languageupdater.py
parent57f58295a48dfa4d893eb1546c5f2f64133c0e7f (diff)
Added number parsing capabilities
See commands.tmp for an example.  It's pretty neat, but it could still
use some work.  I thought of a really clever way to parse numbers, better
than the one I came up with last night, but since I have a working
implementation now I figure I'd better commit it.

We have a new bug which causes the dictionary to be updated every time the
program starts.  I hope I didn't force that to happen last night or
something, but I have a vague feeling I did.
Diffstat (limited to 'languageupdater.py')
-rw-r--r--languageupdater.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/languageupdater.py b/languageupdater.py
index 662a988..afdfc21 100644
--- a/languageupdater.py
+++ b/languageupdater.py
@@ -1,7 +1,7 @@
 # This is part of Kaylee
 # -- this code is licensed GPLv3
-# Copyright 2013 Jezra
 # Copyright 2015 Clayton G. Hobbs
+# Portions Copyright 2013 Jezra
 
 import hashlib
 import json
@@ -56,7 +56,7 @@ class LanguageUpdater:
 
         # Parse response to get URLs of the files we need
         path_re = r'.*<title>Index of (.*?)</title>.*'
-        number_re = r'.*TAR[0-9]*?\.tgz.*'
+        number_re = r'.*TAR([0-9]*?)\.tgz.*'
         for line in r.text.split('\n'):
             # If we found the directory, keep it and don't break
             if re.search(path_re, line):