> > Now as part of the paster create -t myapp , I would like to ask for > few vars like this: > > How can I ask for 1~10 urls of files.
I was able to do it with a "def pre" function under the "class FrameworkTemplate" http://lucasmanual.com/mywiki/Paste#head-fb94caba6fe96594cfdbe779e69cd7f8514a6444 So now I have a list of my urls that I need to process now. vars['myurl'] is a list of urls. 1. Where do I work with 'vars'? Do I still do it in __init__.py under "class FrameworkTemplate(templates.Template)" or? 2. How do I create custom files based on url? So if somebody passed in a .txt I create a txt file based on txt template. If somebody gave me a csv file I create a file based on csv template. For #2 I guess I will be using "create_template(template, output_dir, vars)", and my filenames will be called : +var_name+.txt_tmpl +var_name+.csv_tmpl 3. But where to put above files? 4. Where to put the "create_template" statements, and how would they look? 5. How to create files based on if else statements (if txt create only txt file)? Any info would be appreciated. Thanks Lucas _______________________________________________ Paste-users mailing list [email protected] http://webwareforpython.org/cgi-bin/mailman/listinfo/paste-users
