mirror of
https://github.com/onionshare/onionshare.git
synced 2025-05-04 23:45:04 -04:00
Make it so passing in --persistent [filename] in the CLI, with no other args, will load that persistent mode settings file and start the server, without needing to do other validations like passing in a list of filenames
This commit is contained in:
parent
1bca467ce3
commit
d61fc45862
2 changed files with 37 additions and 26 deletions
|
@ -47,15 +47,12 @@ class OnionThread(QtCore.QThread):
|
|||
self.mode.web.generate_static_url_path()
|
||||
|
||||
# Choose port and password early, because we need them to exist in advance for scheduled shares
|
||||
self.mode.app.stay_open = not self.mode.common.settings.get(
|
||||
"close_after_first_download"
|
||||
)
|
||||
if not self.mode.app.port:
|
||||
self.mode.app.choose_port()
|
||||
if not self.mode.common.settings.get("public_mode"):
|
||||
if not self.mode.settings.get("general", "public"):
|
||||
if not self.mode.web.password:
|
||||
self.mode.web.generate_password(
|
||||
self.mode.common.settings.get("password")
|
||||
self.mode.settings.get("persistent", "password")
|
||||
)
|
||||
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue