From 581813734fc4af7e78e393b4e708359d6a662fd5 Mon Sep 17 00:00:00 2001 From: Firepup Sixfifty Date: Tue, 16 Jul 2024 22:35:52 +0000 Subject: [PATCH] Account for executing directly in help message --- server.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/server.py b/server.py index 26f1414..55090f0 100755 --- a/server.py +++ b/server.py @@ -50,8 +50,9 @@ try: log("Explicitly erasing cached messages") G.msgs = [] elif arg in ["-?", "-h", "--help"]: + filename = filename if filename.startswith("./") else "python3 "+filename print( - f"""python3 {filename} + f"""{filename} All arguments are optional! All areguments are *expected* to only be specified once, if it appears mutliple times, the last one takes priority. The exception to the above rule is `--link`, since you could want to link to multiple other servers. @@ -66,9 +67,9 @@ Accepted arguments: --cwlgd - Crashes the server when outbound links go down Examples: -python3 {filename} --hostname=Fun-chat --link=chat.example.com:65048 --port=92628 -python3 {filename} --no-logs --no-cache -python3 {filename} --address=127.0.0.1 -l -p=7288""" +{filename} --hostname=Fun-chat --link=chat.example.com:65048 --port=92628 +{filename} --no-logs --no-cache +{filename} --address=127.0.0.1 -l -p=7288""" ) exit(0) elif arg in ["-l", "--no-logs"]: