aboutsummaryrefslogtreecommitdiff
path: root/pyaggr3g470r/utils.py
diff options
context:
space:
mode:
authorCédric Bonhomme <cedric@cedricbonhomme.org>2014-06-10 14:41:35 +0200
committerCédric Bonhomme <cedric@cedricbonhomme.org>2014-06-10 14:41:35 +0200
commitd252771f7152a649f6c7ce62da2c22e465d795a8 (patch)
tree6bbeb1934cda0ef6ac4b4e8ce48ddb4fe55aeada /pyaggr3g470r/utils.py
parentNot writing JSON file when importing an account. (diff)
downloadnewspipe-d252771f7152a649f6c7ce62da2c22e465d795a8.tar.gz
newspipe-d252771f7152a649f6c7ce62da2c22e465d795a8.tar.bz2
newspipe-d252771f7152a649f6c7ce62da2c22e465d795a8.zip
fixes #7
Diffstat (limited to 'pyaggr3g470r/utils.py')
-rwxr-xr-xpyaggr3g470r/utils.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/pyaggr3g470r/utils.py b/pyaggr3g470r/utils.py
index 336ec804..dcbf5027 100755
--- a/pyaggr3g470r/utils.py
+++ b/pyaggr3g470r/utils.py
@@ -42,9 +42,9 @@ import logging
import datetime
import operator
import urllib
+import subprocess
from urlparse import urlparse, parse_qs, urlunparse
from bs4 import BeautifulSoup
-
from collections import Counter
from contextlib import contextmanager
@@ -75,6 +75,9 @@ def opened_w_error(filename, mode="r"):
finally:
f.close()
+def fetch(email, feed_id=None):
+ cmd = ['python', conf.basedir+'/fetch.py', email, str(feed_id)]
+ p = subprocess.Popen(cmd, stdout=subprocess.PIPE)
def import_opml(email, opml_content):
"""
bgstack15