Skip to content

Instantly share code, notes, and snippets.

View spookyahell's full-sized avatar
🌐
Browsing the WWW (and helping others and myself get through life)

spookyahell

🌐
Browsing the WWW (and helping others and myself get through life)
View GitHub Profile
@spookyahell
spookyahell / README.md
Created January 24, 2024 17:08
Beanstandung Rechnung

Sehr geehrter Damen und Herren, es besteht sehr wohl ein Grund zur Beanstandung der Rechnung.

In diesem Krankenhausaufenthalt wurde ich - aus eigener Sichtweise, auch heute noch - recht schlimm vom Personal, vor allem von Ärzten des Krankenhauses und des Ärzteteams behandelt.

Der Aufenthalt war eine Art Offenbarung.

Ich habe mehrfach auf eigene Faust das Klinikgelände verlassen, um die Wohngruppe, von der ich bis kurz vor Entlassung noch ein Teil war, zu besuchen und um den "Gestank vom Klinik-Aufenthalt" zu entkommen.

Ich ärgere mich bis heute, dass ich nicht viel früher einfach um Entlassung gebeten habe. Hätte ich vermutlich auf Station 3.1 tun können. Mein schlechter Zustand war eine Phase und hätte sich - vermutlich egal wo ich mich befinde - gebessert. Vielleicht wäre es auch schneller zu einer Genesung gekommen, in einem gewohntem Umfeld.

from os import sep
from os.path import isfile
import requests
bravo_files = [
'BRAVO 1956-01original.pdf',
'BRAVO 1957*1994-01.pdf',
'Starschnitt_081_E.T.zip'
]
@spookyahell
spookyahell / cds.py
Last active February 19, 2023 14:04
Place this in your path (and add .py to PATHEXT if not already done so) to be able to swtich to between seasons seamlessly)
import sys, re
from os import getcwd, remove, sep
from subprocess import call
season = sys.argv[1]
cwd = getcwd()
switch_to = re.sub(r'S(\d+)', f'S{int(season):02}', cwd)
call(['cmd', '/k', f'TITLE {switch_to.split(sep)[-1]} (in {sep.join(switch_to.split(sep)[:-1])})'], cwd = switch_to)
@spookyahell
spookyahell / cd2.py
Last active February 19, 2023 12:59
Place in your PATH (and add .py to PATHEXT if not already done so) for a better Windows Console title experience
# v0.1 by spookyahell
import sys, re
from os import remove, sep
from os.path import abspath, isdir
from subprocess import call, check_output
if not isdir(sys.argv[1]):
print('ERROR: The path you want to switch to does NOT exist.')
sys.exit(1)
@spookyahell
spookyahell / telegram_sm.py
Last active January 16, 2023 09:39
TDSM (stop thinking so dirty!) — Telegram Desktop Session (tdata) Manager
'''TDSM (stop thinking so dirty!) — Telegram Desktop Session (tdata) Manager by @spookyahell-->Github.com'''
'''License: MIT with the following addition: The line above this one (or at the very top of the file) may not be removed at any point in any future version of the file and must for ever be included. Unless for a very good technical reason, the details of which could be discussed with vidner123@gmail.com, do NOT rename the file. You can probably go ahead and rename the file despite not having heard back. After 48h, probably don't expect an answer anymore.
Here are some alternative file name suggestions that don't require prior approval of any form:
tgsm.py, tg_sm.py, tdsm.py, td_sm.py
Please specifically refrain from calling the file profane names;
there's already too much profanity out there. No need for more.'''
from subprocess import check_output, call, Popen, PIPE
from time import sleep
from os import environ, rename, sep, listdir
from os.path import isdir
@spookyahell
spookyahell / convert_colors.py
Last active December 11, 2022 09:54
Dumb vs smart functions (python): How eval can be helpful to remove a bunch of "repetitive code"
'''Using the smart method saves over 75% by line numbers ...
with chars/bytes it's 394 vs. 1220 chars which is "only" saves 67% of code
(All types of comments and extra lines were removed before comparision)'''
def convert_color_markdown(inp):
accepted_opts = 'black|red|green|magenta|cyan|blue|yellow|white|reset|reset_all|dim|normal|bright'
find_markdowns = re.findall(fr'(\[([sbf])=({accepted_opts})])', inp)#~ print(find_markdowns)
for markdown in find_markdowns:
type_lookup = {'f':'Fore','b':'Back','s':'Style'} #~ type, color = markdown[0].strip('[]').split('=')
inp = inp.replace(markdown[0], eval(f'colorama.{type_lookup[markdown[1]]}.{markdown[2].upper()}'))
@spookyahell
spookyahell / sf.py
Created January 16, 2022 22:49
sf.py v1.0 - split large files for TG (by @spookyahell)
#!/usr/bin/python3.6
from subprocess import call
from sys import argv
del argv[0]
if len(argv) < 1:
print('sf.py v1.0 - split large files for TG (by @spookyahell)')
else:
call(['/root/Downloads/rar/rar/rar','a', '-v2000M','-m0',f'{argv[0]}.rar', argv[0]])
@spookyahell
spookyahell / letter.md
Last active November 6, 2020 01:18
OPEN LETTER 🤲✉ to THE DIVIDED STATES OF AMERICA (The DSA)

OPEN LETTER 🤲✉ to THE DIVIDED STATES OF AMERICA (The DSA)

What Trump, his supporters & people who vote for him are

Trump is so much asshole, so zenophobic, disgusting etc.

So I have a message for all Trump voters & supporters out there - both "secret voters" that don't show up in polls - and the regular kind:
You are what he is. Through and through, all the way.

In 2016 maybe you could say "I wasn't aware" but even then it was lazy.
Now you're just wrecking the country willingfully... but sure, why not, go ahead.

@spookyahell
spookyahell / amazon_list_fetch.py
Created October 9, 2020 00:12
Amazon.de Items Fetcher (436 0.97€ for Prime customers [DE])
import requests
import json
import sys
from time import sleep
UA = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4284.0 Safari/537.36'
#Variablen initialisieren
index = 0
@spookyahell
spookyahell / PreviousTVSreview.md
Created July 19, 2020 22:23
Ältere TVSMILES Bewertung

Also die App selbst funktioniert bei mir zwar einigermaßen, jedoch gibts aus mehreren Gründen nur 1 Stern für die App: 1. Grund: Immer wieder kommt es zu abstürzen (ja wie gesagt es geht einigermaßen aber schon recht oft stürzt sie ab) 2. Grund: Ich habe bereits öfter mal eine Mail unter anderem auch wegen fehlender SMILES (ja, 30 tage sind schon um) von einem "Deal" und bin deswegen immer noch stinksauer 3. Grund: Ich hörte dass wohl einmal PayPal als Auszahlung möglich war und dass es zu gewinnspielen teilw. noch möglich ist und das finde ich ebenfalls nicht gut, dass es generell nicht möglich ist.. 4. Grund: Man kann sich nicht einmal aus der App ausloggen sondern muss dafür (gott sei dank, android) die App infos aufrufen und dann die Daten löschen, wenn man z.b. nen Kumpel spielen lassen will auf dem eigenen Handy (mit seinem "7Pass Account")