mirror of
https://github.com/jayofelony/pwnagotchi.git
synced 2025-07-01 18:37:27 -04:00
Add a interactive configuration installer
This commit is contained in:
@ -171,6 +171,7 @@ if __name__ == '__main__':
|
|||||||
if pwn_check.lower() in ('y', 'yes'):
|
if pwn_check.lower() in ('y', 'yes'):
|
||||||
os.system("mv -f /etc/pwnagotchi/config.toml /etc/pwnagotchi/config.toml.bak")
|
os.system("mv -f /etc/pwnagotchi/config.toml /etc/pwnagotchi/config.toml.bak")
|
||||||
with open("/etc/pwnagotchi/config.toml", "a+") as f:
|
with open("/etc/pwnagotchi/config.toml", "a+") as f:
|
||||||
|
f.write("# Do not edit this file if you do not know what you are doing!!!\n\n")
|
||||||
# Set pwnagotchi name
|
# Set pwnagotchi name
|
||||||
print("Welcome to the interactive installation of your personal Pwnagotchi configuration!\n"
|
print("Welcome to the interactive installation of your personal Pwnagotchi configuration!\n"
|
||||||
"My name is Jayofelony, how may I call you? ")
|
"My name is Jayofelony, how may I call you? ")
|
||||||
@ -178,8 +179,7 @@ if __name__ == '__main__':
|
|||||||
if pwn_name == "":
|
if pwn_name == "":
|
||||||
pwn_name = "Pwnagotchi"
|
pwn_name = "Pwnagotchi"
|
||||||
print("I shall go by Pwnagotchi from now on!")
|
print("I shall go by Pwnagotchi from now on!")
|
||||||
pwn_name = ("# Do not edit this file if you do not know what you are doing!!!\n\n"
|
pwn_name = "main.name = \"" + pwn_name + "\"\n"
|
||||||
"main.name = \"") + pwn_name + "\"\n"
|
|
||||||
f.write(pwn_name)
|
f.write(pwn_name)
|
||||||
else:
|
else:
|
||||||
print("I shall go by %s from now on!", pwn_name)
|
print("I shall go by %s from now on!", pwn_name)
|
||||||
|
Reference in New Issue
Block a user