aboutsummaryrefslogtreecommitdiff
path: root/utils.py
diff options
context:
space:
mode:
authorcedricbonhomme <devnull@localhost>2011-04-20 13:22:05 +0200
committercedricbonhomme <devnull@localhost>2011-04-20 13:22:05 +0200
commiteea6fb8e963a1aa26b1d6c7a9c089846b9109cae (patch)
tree51cb445909f38f75a87a89715c47b1ded97a7517 /utils.py
parentRelease 2.7. Minor improvements. It is now possible to set a maximum number o... (diff)
downloadnewspipe-eea6fb8e963a1aa26b1d6c7a9c089846b9109cae.tar.gz
newspipe-eea6fb8e963a1aa26b1d6c7a9c089846b9109cae.tar.bz2
newspipe-eea6fb8e963a1aa26b1d6c7a9c089846b9109cae.zip
It is now possible to set the maximum number of articles per feed in the configuration file.
Diffstat (limited to 'utils.py')
-rwxr-xr-xutils.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/utils.py b/utils.py
index 131cf643..5587ce0e 100755
--- a/utils.py
+++ b/utils.py
@@ -62,14 +62,13 @@ config = ConfigParser.RawConfigParser()
config.read("./cfg/pyAggr3g470r.cfg")
path = os.path.abspath(".")
sqlite_base = os.path.abspath(config.get('global', 'sqlitebase'))
+MAX_NB_ARTICLES = int(config.get('global', 'max_nb_articles'))
mail_from = config.get('mail','mail_from')
mail_to = config.get('mail','mail_to')
smtp_server = config.get('mail','smtp')
username = config.get('mail','username')
password = config.get('mail','password')
-MAX_NB_ARTICLES = -1
-
# regular expression to chech URL
url_finders = [ \
re.compile("([0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}|(((news|telnet|nttp|file|http|ftp|https)://)|(www|ftp)[-A-Za-z0-9]*\\.)[-A-Za-z0-9\\.]+)(:[0-9]*)?/[-A-Za-z0-9_\\$\\.\\+\\!\\*\\(\\),;:@&=\\?/~\\#\\%]*[^]'\\.}>\\),\\\"]"), \
bgstack15