From 3b31441651199c4312d59d4061f60f1e08808759 Mon Sep 17 00:00:00 2001 From: Aarik Pokras Date: Mon, 23 Jan 2023 12:56:37 -0500 Subject: [PATCH] Added command `zipfile` --- cmd.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/cmd.py b/cmd.py index be91a3b..657e7bc 100644 --- a/cmd.py +++ b/cmd.py @@ -1,4 +1,5 @@ import os +import shutil import random import maskpass import start @@ -81,6 +82,10 @@ def cls(): elif cmdLine == "magic8ball": ball = ['It is certain.', 'It is so.', 'Without a doubt.', 'Yes.', 'You can count on it.', 'As I see it, yes.', 'Most likely.', 'Outlook is good.', 'Absolutely.', 'All signs point to yes.', 'Reply hazy, try again.', 'Ask again later.', 'Better not tell you now.', 'Cannot predict now.', 'Concentrate and ask again.', 'Don\'t count on it.', 'My reply is no.', 'All signs point to no.', 'Outlook not so good.', 'Doubtful.'] print(random.choice(ball)) + elif cmdLine == "zipfile": + zipfilen=input("Desired zipfile name: ") + zipfiledir=input('Enter directory to zip: ') + shutil.make_archive(zipfilen, 'zip', zipfiledir) elif cmdLine == "custcol": custcolc=input("Enter color: ") if custcolc == "default":