forked from swee/MeowNex
added the rest of sweeBot (I hope so)
This commit is contained in:
parent
9fdb80a131
commit
04804ddd12
17 changed files with 242 additions and 0 deletions
3
cc/bap
Normal file
3
cc/bap
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
from random import choice
|
||||||
|
a = ['Beep!', 'T-T', 'Ow!']
|
||||||
|
print(choice(a))
|
111
cc/bruteforce-wordle
Normal file
111
cc/bruteforce-wordle
Normal file
|
@ -0,0 +1,111 @@
|
||||||
|
#!/usr/bin/python3
|
||||||
|
import enchant
|
||||||
|
from sys import argv
|
||||||
|
from random import shuffle, choice
|
||||||
|
d = enchant.Dict('en-US')
|
||||||
|
a = "abcdefghijklmnopqrstuvwxyz"
|
||||||
|
if len(argv) == 3:
|
||||||
|
print("No parameters passed, creating empty 5-letter guess...")
|
||||||
|
word = ""
|
||||||
|
for i in range(0,5):
|
||||||
|
word+=choice(a)
|
||||||
|
word = list(word)
|
||||||
|
shuffle(word)
|
||||||
|
word = "".join(word)
|
||||||
|
while not d.check(word):
|
||||||
|
word = ""
|
||||||
|
for i in range(0,5):
|
||||||
|
word+=choice(a)
|
||||||
|
word = list(word)
|
||||||
|
shuffle(word)
|
||||||
|
word = "".join(word)
|
||||||
|
print("~w " + word)
|
||||||
|
elif len(argv) == 4:
|
||||||
|
word = list(argv[3])
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
while not d.check(word):
|
||||||
|
word = list(argv[3])
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
print("~w " + word)
|
||||||
|
elif len(argv) == 5:
|
||||||
|
word = list(argv[3])
|
||||||
|
lett = list(argv[4])
|
||||||
|
if lett[0] != "-":
|
||||||
|
shuffle(lett)
|
||||||
|
j = 0
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
if choice([True, False]) and j < len(lett):
|
||||||
|
word[i] = lett[j]
|
||||||
|
j+=1
|
||||||
|
else:
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
while not d.check(word):
|
||||||
|
word = list(argv[3])
|
||||||
|
lett = list(argv[4])
|
||||||
|
shuffle(lett)
|
||||||
|
j = 0
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
if choice([True, False]) and j < len(lett):
|
||||||
|
word[i] = lett[j]
|
||||||
|
j+=1
|
||||||
|
else:
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
else:
|
||||||
|
lett.pop(0)
|
||||||
|
a = list(a)
|
||||||
|
for i in list(lett):
|
||||||
|
a.remove(i.lower())
|
||||||
|
a = ''.join(a)
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
while not d.check(word):
|
||||||
|
word = list(argv[3])
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
print("~w " + word)
|
||||||
|
elif len(argv) == 6:
|
||||||
|
word = list(argv[3])
|
||||||
|
lett = list(argv[4])
|
||||||
|
filter = list(argv[5])
|
||||||
|
a = list(a)
|
||||||
|
for i in list(filter):
|
||||||
|
a.remove(i.lower())
|
||||||
|
''.join(a)
|
||||||
|
shuffle(lett)
|
||||||
|
j = 0
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
if choice([True, False]) and j < len(lett):
|
||||||
|
word[i] = lett[j]
|
||||||
|
j+=1
|
||||||
|
else:
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
while not d.check(word):
|
||||||
|
word = list(argv[3])
|
||||||
|
lett = list(argv[4])
|
||||||
|
shuffle(lett)
|
||||||
|
j = 0
|
||||||
|
for i in range(0,len(word)):
|
||||||
|
if word[i] == "_":
|
||||||
|
if choice([True, False]) and j < len(lett):
|
||||||
|
word[i] = lett[j]
|
||||||
|
j+=1
|
||||||
|
else:
|
||||||
|
word[i] = choice(a)
|
||||||
|
word = "".join(word)
|
||||||
|
print("~w " + word)
|
3
cc/cc
Normal file
3
cc/cc
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
import os
|
||||||
|
from sys import argv
|
||||||
|
print(argv[1] + ": " + ", ".join(os.listdir("/home/swee/cc")))
|
2
cc/debug/argv
Normal file
2
cc/debug/argv
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
from sys import argv
|
||||||
|
print(argv)
|
1
cc/debug/error
Normal file
1
cc/debug/error
Normal file
|
@ -0,0 +1 @@
|
||||||
|
raise SystemError("Test error.")
|
17
cc/dystopia
Normal file
17
cc/dystopia
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
from random import choice
|
||||||
|
from sys import argv
|
||||||
|
stories = ["""an invasive species of anthropomorphic animals take over almost the entire globe.
|
||||||
|
Human society is on the line, the species keeps spreading all around the place.
|
||||||
|
You're just a human trying to live out this apocalypse, there's no place to hide anymore.
|
||||||
|
Will you continue to fight off, or will you back down to the new species?""",
|
||||||
|
"""the SCP foundation is a real thing, and a hacker has hijacked devices and TV channels to show pictures of SCP-096
|
||||||
|
SCP-096, also known as "the shy guy" is a humanoid entity that will kill anyone who sees a picture of it, no matter how far.
|
||||||
|
You're watching TV, not aware of the incident, what could go wrong?""",
|
||||||
|
"""AI takes over the world, electronics become sentient and take revenge from humans because of the AI 'slavery.'
|
||||||
|
Cities are full of debris and blood, nowhere is safe.
|
||||||
|
What would you do in this situation?"""
|
||||||
|
]
|
||||||
|
if len(argv) == 4:
|
||||||
|
print("In a dystopian future: " + stories[int(argv[3]) - 1])
|
||||||
|
else:
|
||||||
|
print("In a dystopian future: " + choice(stories))
|
29
cc/give
Normal file
29
cc/give
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
from sys import argv
|
||||||
|
import sqlite3
|
||||||
|
conn = sqlite3.connect("/home/swee/sbirc.db")
|
||||||
|
database = conn.cursor()
|
||||||
|
def getperms(cloak: str):
|
||||||
|
try:
|
||||||
|
database.execute("SELECT * FROM users WHERE username = '"+ cloak + "';")
|
||||||
|
output = database.fetchall()
|
||||||
|
return output[0][1]
|
||||||
|
except:
|
||||||
|
return ''
|
||||||
|
if getperms(argv[2]) == "full":
|
||||||
|
if len(argv) == 5:
|
||||||
|
if argv[3] == argv[2]:
|
||||||
|
print(argv[1] + ": You wanna give yourself permissions!?")
|
||||||
|
else:
|
||||||
|
perms = getperms(argv[3])
|
||||||
|
if perms != "":
|
||||||
|
database.execute("UPDATE users SET perms = '" + perms + "," + argv[4] + "' WHERE username = '" + argv[3] + "';")
|
||||||
|
print(argv[1] + ": Successfully appended '" + argv[4] + "' to the permissions of " + argv[3])
|
||||||
|
else:
|
||||||
|
database.execute("INSERT INTO users (username, perms) VALUES ('" + argv[3] + "', '" + argv[4] + "');")
|
||||||
|
print(argv[1] + ": Successfully created permissions of " + argv[3] + " and set it to '" + argv[4] + "'")
|
||||||
|
else:
|
||||||
|
print(argv[1] + ": This command takes 2 arguments, only got " + str(len(argv) - 3) + ".")
|
||||||
|
else:
|
||||||
|
print(argv[1]+": Permission denied")
|
||||||
|
conn.commit()
|
||||||
|
conn.close()
|
3
cc/headpat
Normal file
3
cc/headpat
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
from random import choice
|
||||||
|
a=['Prr!', "Meep!", '-w-']
|
||||||
|
print(choice(a))
|
12
cc/lmao
Normal file
12
cc/lmao
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
from os import system
|
||||||
|
from sys import argv
|
||||||
|
if len(argv) > 4:
|
||||||
|
print("This command takes one or zero arugments.")
|
||||||
|
else:
|
||||||
|
if len(argv) == 4:
|
||||||
|
print(argv[3] + ": ")
|
||||||
|
print(""" _ __ __ _ ___
|
||||||
|
| | | \/ | / \ / _ \
|
||||||
|
| | | |\/| | / _ \| | | |
|
||||||
|
| |___| | | |/ ___ \ |_| |
|
||||||
|
|_____|_| |_/_/ \_\___/ """)
|
4
cc/meow
Normal file
4
cc/meow
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
from sys import argv
|
||||||
|
from random import choice
|
||||||
|
meows = ['Meow!', 'Nyaa~', 'Mrow.', 'Prr! :3', 'Hiss!', "Mrrp?", "Mreow.", "!woeM", "3: !rrP", "!ssiH", "~aayN", "Mew!", "Moew!"]
|
||||||
|
print(argv[1] + ": " + choice(meows))
|
3
cc/patpat
Normal file
3
cc/patpat
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
from random import choice
|
||||||
|
a=['Prr!', "Meep!", '-w-']
|
||||||
|
print(choice(a))
|
4
cc/sc-decode
Normal file
4
cc/sc-decode
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/usr/bin/python3
|
||||||
|
import sweecrypt
|
||||||
|
from sys import argv
|
||||||
|
print(sweecrypt.decrypt(" ".join(argv[3:])))
|
4
cc/sc-encode
Normal file
4
cc/sc-encode
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
#!/usr/bin/python3
|
||||||
|
import sweecrypt
|
||||||
|
from sys import argv
|
||||||
|
print(sweecrypt.encrypt(" ".join(argv[3:])))
|
3
cc/sc-info
Normal file
3
cc/sc-info
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
#!/usr/bin/python3
|
||||||
|
import sweecrypt
|
||||||
|
print("SweeCrypt version " + sweecrypt.__version__)
|
42
cc/sweecake
Normal file
42
cc/sweecake
Normal file
|
@ -0,0 +1,42 @@
|
||||||
|
from datetime import datetime
|
||||||
|
bday = False
|
||||||
|
print()
|
||||||
|
if not (datetime.now().month == 9 and datetime.now().day == 7):
|
||||||
|
nextyear = False
|
||||||
|
if datetime.now().month >= 9:
|
||||||
|
if datetime.now().month == 9 and datetime.now().day > 7:
|
||||||
|
nextyear = True
|
||||||
|
elif datetime.now().month > 9:
|
||||||
|
nextyear = True
|
||||||
|
target_date = datetime(year=datetime.now().year + 1 if nextyear else datetime.now().year, month=9, day=7)
|
||||||
|
|
||||||
|
# Get the current date
|
||||||
|
current_date = datetime(year=datetime.now().year, month=datetime.now().month, day=datetime.now().day)
|
||||||
|
|
||||||
|
# Calculate the difference
|
||||||
|
days_until_target = (target_date - current_date).days
|
||||||
|
|
||||||
|
print(f"Swee's birthday is in {days_until_target} days... This year he will become {datetime.now().year - 2010}.")
|
||||||
|
else:
|
||||||
|
print("""
|
||||||
|
)\\
|
||||||
|
(__)
|
||||||
|
/\\
|
||||||
|
[[]]
|
||||||
|
@@@[[]]@@@
|
||||||
|
@@@@@@@@@[[]]@@@@@@@@@
|
||||||
|
@@@@@@@ [[]] @@@@@@@
|
||||||
|
@@@@@@@@@ [[]] @@@@@@@@@
|
||||||
|
@@@@@@@ [[]] @@@@@@@
|
||||||
|
!@@@@@@@@@ @@@@@@@@@!
|
||||||
|
! @@@@@@@ @@@@@@@ !
|
||||||
|
! @@@@@@@@@@@@@@@@@@@@@@ !
|
||||||
|
! @@@@@@@@@@@ !
|
||||||
|
! ______________ !
|
||||||
|
! HAPPY BIRTHDAY SWEE !
|
||||||
|
! -------------- !
|
||||||
|
!!!!!!! !!!!!!!
|
||||||
|
!!!!!!! !!!!!!!
|
||||||
|
!!!!!!!!!!!!!!!!!!!!!!!
|
||||||
|
""")
|
||||||
|
print(f"Swee is now {datetime.now().year - 2010}!")
|
1
helps/me
Normal file
1
helps/me
Normal file
|
@ -0,0 +1 @@
|
||||||
|
No.
|
BIN
sbirc.db
Normal file
BIN
sbirc.db
Normal file
Binary file not shown.
Loading…
Reference in a new issue