if out-dir does not exist, it will be created

This commit is contained in:
Marcus "Chaosblog 2012-01-19 20:03:49 +01:00
parent c0c09a95f0
commit ed571c48c3

View file

@ -3,12 +3,15 @@ import yaml
import feedparser
import datetime
import sys
import os
from dateutil.parser import parse
import dateutil.tz as tz
with open('bloggers.yml') as f:
users = yaml.safe_load(f.read())
if not os.path.exists('out'):
os.makedirs('out')
try:
with open('out/report.yml') as f:
log = yaml.safe_load(f.read())