Skip to content

Instantly share code, notes, and snippets.

@ramast
ramast / pulse-recorder.py
Last active May 30, 2020
Record a program's output with PulseAudio
View pulse-recorder.py
#!/usr/bin/env python3
# Based on code from these stackoverflow answers:
# https://askubuntu.com/questions/60837/record-a-programs-output-with-pulseaudio/910879#910879
import re
import subprocess
import sys
import os
import signal
from time import sleep
@nvsofts
nvsofts / fastboot.txt
Created Dec 3, 2018
PlayStation Classic boot log
View fastboot.txt
Watchdog Status: 0 , boot from normal
mt_pll_init +
CLK_GATING_CTRL1:d891923e
after set, CLK_GATING_CTRL1:d891923e
CLK_GATING_CTRL2:7afdbf10
[PWRAP] pmic ID: 2092.
[EMI] MDL number = 0
[EMI] PCDDR3
Vcore HV NV LV, Vdram HV NV LV
0x5f 0x48 0x3f, 0xc 0x0 0x3
@bparker06
bparker06 / retromods.md
Created Sep 4, 2018 — forked from leiradel/retromods.md
Retromods spec brain dump. *Highly volatile!*
View retromods.md

Retromods

What is a mod?

A mod is a set of code and assets that changes or augments the way a game is run. Examples of mods are:

  • Music and sound packs that replace the original game music and sound.
  • Graphics packs that replace the original game graphics.
  • Level packs that change or replace the original game levels.
  • Achievements that are awarded to the players when they complete tasks in the game.
@awhatson
awhatson / msys2_downgrade.py
Last active Aug 24, 2018
Helper script for downgrading MSYS2
View msys2_downgrade.py
#!/usr/bin/env python3
from argparse import ArgumentParser
from datetime import datetime, timedelta
from pathlib import Path
import json
import re
import subprocess
import sys
import tempfile
@vgmoose
vgmoose / matterbridge.toml
Created Feb 8, 2018
mattermost irc to discord bridge for switchbru, replace [INSERTBOTTOKEN] with discord access token, see: https://github.com/42wim/matterbridge/wiki/Discord-bot-setup for discord bot config
View matterbridge.toml
[irc]
[irc.freenode]
Server="irc.freenode.net:6667"
Nick="botircnickname"
RemoteNickFormat="<{NICK}> "
[discord]
[discord.test]
Token="[INSERTBOTTOKEN]"
Server="WiiUBru & SwitchBru"
@ErikAugust
ErikAugust / spectre.c
Last active Jun 28, 2020
Spectre example code
View spectre.c
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#ifdef _MSC_VER
#include <intrin.h> /* for rdtscp and clflush */
#pragma optimize("gt",on)
#else
#include <x86intrin.h> /* for rdtscp and clflush */
#endif
View 10-ssl.conf
# Replace [YOUR_DOMAIN_NAME] by your real domain
server.modules += ( "mod_setenv" ) # For HSTS
$SERVER["socket"] == "0.0.0.0:443" {
ssl.engine = "enable"
ssl.pemfile = "/etc/letsencrypt/live/[YOUR_DOMAIN_NAME]/combined.pem"
ssl.ca-file = "/etc/letsencrypt/live/[YOUR_DOMAIN_NAME]/fullchain.pem"
ssl.dh-file = "/etc/ssl/certs/dhparam.pem"
View msys2-environment.txt
HOMEPATH=\Users\abdo
USERDOMAIN_ROAMINGPROFILE=WINDOWS10
LDFLAGS=-pipe
MANPATH=/mingw64/share/man:/usr/local/man:/usr/share/man:/usr/man:/share/man
APPDATA=C:\Users\abdo\AppData\Roaming
LESS_TERMCAP_mb=
ORIGINAL_TEMP=/c/Users/abdo/AppData/Local/Temp
ProgramW6432=C:\Program Files
MSYS_ROOT=D:\msys64
HOSTNAME=windows10
@Saturate
Saturate / GetAllWifiPasswords.ps1
Last active Mar 10, 2020
PowerShell Wifi Script
View GetAllWifiPasswords.ps1
# Run this script as an Admin user and get a list of all WiFi passwords.
$listProfiles = netsh wlan show profiles | Select-String -Pattern "All User Profile" | %{ ($_ -split ":")[-1].Trim() };
$listProfiles | foreach {
$profileInfo = netsh wlan show profiles name=$_ key="clear";
$SSID = $profileInfo | Select-String -Pattern "SSID Name" | %{ ($_ -split ":")[-1].Trim() };
$Key = $profileInfo | Select-String -Pattern "Key Content" | %{ ($_ -split ":")[-1].Trim() };
[PSCustomObject]@{
WifiProfileName = $SSID;
Password = $Key
}
@gromnitsky
gromnitsky / gmake-patsubst.c
Last active Apr 4, 2018
An extract of patsubst function from GNU Make
View gmake-patsubst.c
/*
An extract of patsubst function from GNU Make 4.2.90
(6f339b22eb87dc80d1037ccb04c787d156db0e8f)
$ cc gmake-patsubst.c -o gmake-patsubst
$ ./gmake-patsubst %.c %.o 'foo.c bar.c'
foo.o bar.o
*/
#include <stdio.h>
You can’t perform that action at this time.