Skip to content

Instantly share code, notes, and snippets.

View jh0ker's full-sized avatar
🚀
Hacking

Jannes Höke jh0ker

🚀
Hacking
View GitHub Profile
@nigma
nigma / serve.py
Created December 20, 2012 22:44
Serving Django with CherryPy
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import os
import webbrowser
from threading import Timer
os.environ["DJANGO_SETTINGS_MODULE"] = "webapp.settings"
import cherrypy
@junian
junian / twitch-recorder.py
Last active March 26, 2024 12:31
Record Twitch Streams Automatically in Python
# This code is based on tutorial by slicktechies modified as needed to use oauth token from Twitch.
# You can read more details at: https://www.junian.net/2017/01/how-to-record-twitch-streams.html
# original code is from https://slicktechies.com/how-to-watchrecord-twitch-streams-using-livestreamer/
import requests
import os
import time
import json
import sys
import subprocess
@quonic
quonic / scum_sqlite.ps1
Last active September 3, 2022 22:16
For the game SCUM. This sets stats too 5 and skills to 4 for specified character.
#Requires -Module PSSQLite
param(
[Alias('Name', '')]
[string]
$ProfileName
)
<#
Updated for 9/2 patch
Updated by request of Truth91
#>
@adrianlzt
adrianlzt / sharescreen
Last active January 7, 2022 07:14
Scripts to share only a portion of the screen
#!/bin/bash
# Modified version of https://github.com/Ashark/hliss/blob/master/vlc-hangouts
# Script to share a portion of the screen in VLC to be used by Chrome/Firefox to share the screen
# By default, when run, it asks to click in some window. The area of that window is what is going to be shared.
# If executed with "sharescreen area", it asks for a portion of the screen to be shared.
unset x y w h
# Old code to choose a monitor
@benigumocom
benigumocom / debug_from_qr.py
Last active June 12, 2024 14:56
Connect Wireless Debug from Terminal on Android11
#!/usr/bin/env python3
"""
Android11
Pair and connect devices for wireless debug on terminal
python-zeroconf: A pure python implementation of multicast DNS service discovery
https://github.com/jstasiak/python-zeroconf
"""
from typing import Any, Dict, List, Mapping, Union
# Values for JSON that aren't nested
JSON_v = Union[str, int, float, bool, None]
# If MyPy ever permits recursive definitions, just uncomment this:
# JSON = Union[List['JSON'], Mapping[str, 'JSON'], JSON_v]
# Until then, here's a multi-layer way to represent any (reasonable) JSON we
# might send or receive. It terminates at JSON_4, so the maximum depth of
@spajus
spajus / WreckedEmptyShipScenario.cs
Created October 13, 2022 08:14
Stardeus scenario example code
using System.Collections;
using Game.Audio;
using Game.Constants;
using Game.Data;
using Game.Procgen;
using Game.Story.Events;
using Game.Systems.Goals;
using Game.Utils;
using KL.Randomness;
using KL.Utils;