From d79c1b3a6d1a6481b77598edf71fcb53eb6bb655 Mon Sep 17 00:00:00 2001 From: RaNaN Date: Fri, 18 Feb 2011 22:33:06 +0100 Subject: closed #242, #243, #244 --- module/setup.py | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) (limited to 'module/setup.py') diff --git a/module/setup.py b/module/setup.py index f7b5839e0..39352d6d3 100644 --- a/module/setup.py +++ b/module/setup.py @@ -20,14 +20,11 @@ from getpass import getpass import gettext from hashlib import sha1 import os -from os import remove from os import makedirs from os.path import abspath from os.path import dirname from os.path import exists -from os.path import isfile from os.path import join -import random import re from subprocess import PIPE from subprocess import call @@ -50,6 +47,22 @@ class Setup(): translation = gettext.translation("setup", join(self.path, "locale"), languages=["en", lang]) translation.install(True) + print "" + print _("Would you like to configure pyLoad via Webinterface?") + print _("You need a Browser and a connection to this PC for it.") + viaweb = self.ask(_("Start initial webinterface for configuration?"), "y", bool=True) + if viaweb: + try: + from module.web import ServerThread + ServerThread.setup = self + from module.web import webinterface + webinterface.run_simple() + return False + except Exception, e: + print "Setup failed with this error: ", e + print "Falling back to commandline setup." + + print "" print _("Welcome to the pyLoad Configuration Assistent.") print _("It will check your system and make a basic setup in order to run pyLoad.") -- cgit v1.2.3