Skip to content

Instantly share code, notes, and snippets.

View micash545's full-sized avatar

Micash micash545

View GitHub Profile
@micash545
micash545 / deb11vaultwardenInstall.md
Created October 5, 2023 20:26
Debian 11 Vaultwarden install (no docker)
{
"api": {
"id": null,
"worker-id": null
},
"http": { "enabled": false,
"host": "127.0.0.1",
"port": 0, "access-token": null,
"restricted": true },
"autosave": true,
from itertools import product
string = "abc"
# Generate all combinations and print them
for i in range(1, len(string) + 1):
for combination in product(string, repeat=i):
print(''.join(combination))
#output

Macbook Wifi Debian 11

Enable non-free repo

/etc/apt/sources.list:

deb http://deb.debian.org/debian bullseye main contrib non-free
deb-src http://deb.debian.org/debian bullseye main contrib non-free

deb http://deb.debian.org/debian-security/ bullseye-security main contrib non-free
deb-src http://deb.debian.org/debian-security/ bullseye-security main contrib non-free

bash scripts for fast linux setup

curl -s https://gist.githubusercontent.com/micash545/9a165f347ff306d635b5e7e9675df16c/raw/79bc96bb4eaa73a2304bf55bd4df217abe7c27ec/setupdebian-amdgpurocm.sh | bash 
curl -s https://gist.githubusercontent.com/micash545/9a165f347ff306d635b5e7e9675df16c/raw/79bc96bb4eaa73a2304bf55bd4df217abe7c27ec/setupdebian.sh | bash 
#!/bin/bash
apt-get install \
ca-certificates \
curl \
gnupg \
lsb-release
mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
400 read by owner
040 read by group
004 read by anybody
200 write by owner
020 write by group
002 write by anybody
100 execute by owner
010 execute by group
001 execute by anybody
import keyboard
while True:
if keyboard.is_pressed('h'):
print("H pressed")
break
from threading import Thread
def func1():
print('Working')
def func2():
print("Working")
if __name__ == '__main__':
Thread(target = func1).start()
qwerty = ['a','b','c','d','e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z', '1', '2', '3', '4', '5', '6', '7', '8', '9', '0', '!', 'Â', '£', '$', '%', '^', '&', '*', '(', '`', ')', '[', ']', '{', '}', '_']