Formatting
This commit is contained in:
parent
0ff1bcfd19
commit
a187726ba8
1 changed files with 7 additions and 3 deletions
10
src/main.py
10
src/main.py
|
@ -47,7 +47,9 @@ if config.action == "main":
|
||||||
browser = webbrowser.get()
|
browser = webbrowser.get()
|
||||||
else:
|
else:
|
||||||
browser = webbrowser.get(config.open_browser)
|
browser = webbrowser.get(config.open_browser)
|
||||||
browser.open("http://%s:%s/%s" % (config.ui_ip if config.ui_ip != "*" else "127.0.0.1", config.ui_port, config.homepage), new=2)
|
browser.open("http://%s:%s/%s" % (
|
||||||
|
config.ui_ip if config.ui_ip != "*" else "127.0.0.1", config.ui_port, config.homepage
|
||||||
|
), new=2)
|
||||||
except Exception as err:
|
except Exception as err:
|
||||||
print("Error starting browser: %s" % err)
|
print("Error starting browser: %s" % err)
|
||||||
sys.exit()
|
sys.exit()
|
||||||
|
@ -210,7 +212,10 @@ class Actions(object):
|
||||||
import getpass
|
import getpass
|
||||||
privatekey = getpass.getpass("Private key (input hidden):")
|
privatekey = getpass.getpass("Private key (input hidden):")
|
||||||
try:
|
try:
|
||||||
succ = site.content_manager.sign(inner_path=inner_path, privatekey=privatekey, update_changed_files=True, remove_missing_optional=remove_missing_optional)
|
succ = site.content_manager.sign(
|
||||||
|
inner_path=inner_path, privatekey=privatekey,
|
||||||
|
update_changed_files=True, remove_missing_optional=remove_missing_optional
|
||||||
|
)
|
||||||
except Exception as err:
|
except Exception as err:
|
||||||
logging.error("Sign error: %s" % Debug.formatException(err))
|
logging.error("Sign error: %s" % Debug.formatException(err))
|
||||||
succ = False
|
succ = False
|
||||||
|
@ -326,7 +331,6 @@ class Actions(object):
|
||||||
|
|
||||||
print("Downloaded in %.3fs" % (time.time()-s))
|
print("Downloaded in %.3fs" % (time.time()-s))
|
||||||
|
|
||||||
|
|
||||||
def siteNeedFile(self, address, inner_path):
|
def siteNeedFile(self, address, inner_path):
|
||||||
from Site.Site import Site
|
from Site.Site import Site
|
||||||
from Site import SiteManager
|
from Site import SiteManager
|
||||||
|
|
Loading…
Reference in a new issue