Skip to content

Instantly share code, notes, and snippets.

@Chase-san
Chase-san / decode.py
Created September 5, 2021 21:25
A python script to decode the hello games no man's sky save files. (The newer compressed kind)
#!/usr/bin/python3
import io
import os
import lz4.block
from glob import glob
FILE_PATH = os.path.dirname(os.path.realpath(__file__))
def uint32(data):
"""Convert 4 bytes to a little endian unsigned integer."""
@stellasphere
stellasphere / descriptions.json
Last active December 25, 2024 16:50
WMO weather interpretation code descriptions (& images)
{
"0":{
"day":{
"description":"Sunny",
"image":"http://openweathermap.org/img/wn/[email protected]"
},
"night":{
"description":"Clear",
"image":"http://openweathermap.org/img/wn/[email protected]"
}
@uchagani
uchagani / proxmox_usb_passthrough.md
Last active December 25, 2024 16:44
Proxmox USB Passthrough
@disler
disler / README.md
Last active December 25, 2024 16:41
Four Level Framework for Prompt Engineering
@hyunbinseo
hyunbinseo / index.ts
Created June 24, 2023 12:09
Drizzle ORM Cheat Sheet
import { asc, eq, gte, lte } from 'drizzle-orm';
import { drizzle } from 'drizzle-orm/mysql2';
import { createPool } from 'mysql2';
import * as schema from './schema';
import { comments, users } from './schema';
const connection = createPool({
host: '...',
user: '...',
password: '...',
@abrahmandevs
abrahmandevs / JetBrains trial reset.md
Created December 25, 2024 16:30 — forked from h3ssan/JetBrains trial reset.md
Reset all JetBrains products trial in Linux

In some cases, only these lines will work

for product in IntelliJIdea WebStorm DataGrip PhpStorm CLion PyCharm GoLand RubyMine; do
    rm -rf ~/.config/$product*/eval 2> /dev/null
    rm -rf ~/.config/JetBrains/$product*/eval 2> /dev/null
done

But if not, try these

@Konamiman
Konamiman / 0. WiFi for Ethernet-only devices via Raspberry Pi.md
Last active December 25, 2024 16:30
How to use a Raspberry Pi to provide WiFi for Ethernet-only devices, and how to use stunnel as a SOCKS server ro provide indirect TLS support

What's this?

I love MSX computers. I have developed quite a few things for them, including a TCP/IP stack and some networking applications. Some other MSX nerds have developed networking hardware, so boom! Here it is, Internet access from MSX, a 1980s 8 bit machine. How cool is that?

However there are a few issues that prevent us the MSX users to reach the absolute networking happiness:

  1. At the time of this writing, there isn't any solution for wireless Internet for MSX, only Ethernet hardware.
  2. InterNestor Lite, the TCP/IP stack for MSX, doesn't support TLS. It's not that the developer (me!) is too lazy to implement it, it's just that a Z80 can't handle the required encryption algorythms. Trust me, I tried.

So

TLP 1.4 Test: Battery Care for Samsung laptops

Read the overview document first.

Supported Features

Samsung laptops using the samsung_laptop driver have a feature called 'battery life extender', basically a fixed stop charge threshold at 80%. The hardware behaviour is:

  1. Connected to the charger, charging stops when the charge level reaches the stop threshold
@JoeyBurzynski
JoeyBurzynski / Homebrew_How-to-Backup-and-Restore-Homebrew-Packages-2022.md
Last active December 25, 2024 16:27
Homebrew: How to Backup & Restore Homebrew Packages [2022, MacOS]

Homebrew: How to Backup & Restore Homebrew Packages

Homebrew makes it easy to install and keep installed software up to date on your Mac - as part of my backup routine for my Mac I want to be able to run a single command to reinstall all packages.

If you're searching on how to backup & restore Homebrew, then I assume you're here for the commands.

Brewfiles

Brewfiles are files generated with definitions that Homebrew reads and processes, a generated