Skip to content

Instantly share code, notes, and snippets.

@threedaymonk
threedaymonk / format.md
Last active April 26, 2024 13:21
Roland SP-404SX sample format

Roland SP-404SX sample file format

Notes

Field types are marked using C-style notation:

  • char[4] indicates a 4-byte fixed-width string
  • uint[6] indicates a 6-byte sequence
  • uint8, uint16, and uint32 are unsigned byte, short, and long integers
  • int8, int16, and int32 are signed byte, short, and long integers
@fnky
fnky / ANSI.md
Last active May 12, 2024 13:47
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@christopheranderton
christopheranderton / digging-into-wondershare-notes.md
Last active March 19, 2024 14:17
Scratchpad/Notes for digging into the shady business of Wondershare. Not complete (it's a scratchpad after all!)

NOTEPAD : Digging into Wondershare

[See the Host entries at the end of the document]


http://en.0430.com/cn/web86683/

Sharer:	wadmin00126	Category:	software companies

Score: (59) PR: PR:PR:4

@jonathantneal
jonathantneal / recovery.sh
Last active November 10, 2023 01:01
Create or update macOS Big Sur (or Catalina, or Mojave) Recovery Partition Without Reinstalling
#!/bin/sh
# Set the macOS installer path as a variable
MACOS_INSTALLER="/Applications/$(ls /Applications | grep "Install macOS")"
MOUNT_POINT="$MACOS_INSTALLER/Contents/SharedSupport"
echo "macOS installer is \"$MACOS_INSTALLER\""
# Set the target disk as a variable
TARGET=$(diskutil info "$(bless --info --getBoot)" | awk -F':' '/Volume Name/ { print $2 }' | sed -e 's/^[[:space:]]*//')
echo "Target disk is \"$TARGET\""
@mayankk2308
mayankk2308 / disable-amd-gpu.sh
Last active April 12, 2023 02:45
Disable AMD GPU acceleration on macOS
# This can be useful to force the system to use only the integrated GPU at all times.
# This only applies to modern AMD GPUs (using the AMDRadeon4000 series kernel extension or later).
# Set mux to integrated Intel GPU
sudo nvram fa4ce28d-b62f-4c99-9cc3-6815686e30f9:gpu-power-prefs=%01%00%00%00
# Option #1: Completely disable automatic graphics switching and any other GPUs
sudo nvram boot-args="agc=-1"
# Option #2: Disable just the AMD GPU framebuffer
@166MMX
166MMX / 10.12.csv
Last active December 29, 2017 07:23
bundleDisplayName bundleShortVersionString itemId softwareVersionBundleId softwareVersionExternalIdentifier ProductVersion ProductBuildVersion
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 817891742
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818657038
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818744109
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818745269
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818758005
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818806283
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818872651
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 818907548
Install macOS Sierra 1127487414 com.apple.InstallAssistant.Sierra 819278692
@blackgate
blackgate / mbp2011-disable-amd-gpu.md
Last active November 22, 2023 01:23
Macbook Pro 2011 - Disable AMD GPU
@jonbakerfish
jonbakerfish / loop_aria2.sh
Last active February 27, 2023 06:45
aria2 downloads a list of files, loop until all file are finished
#!/bin/bash
aria2c -j5 -i list.txt -c --save-session out.txt
has_error=`wc -l < out.txt`
while [ $has_error -gt 0 ]
do
echo "still has $has_error errors, rerun aria2 to download ..."
aria2c -j5 -i list.txt -c --save-session out.txt
has_error=`wc -l < out.txt`
sleep 10
@nuomi1
nuomi1 / PrintBootCampESDInfo.swift
Last active May 6, 2024 17:05
macOS and BootCamp Latest
#!/usr/bin/env swift
//
// PrintBootCampESDInfo.swift
//
// Created by nuomi1 on 8/5/18.
// Copyright © 2018年 nuomi1. All rights reserved.
//
import Foundation
# "Colorizing B/W Movies with Neural Nets",
# Network/Code Created by Ryan Dahl, hacked by samim.io to work with movies
# BACKGROUND: http://tinyclouds.org/colorize/
# DEMO: https://www.youtube.com/watch?v=_MJU8VK2PI4
# USAGE:
# 1. Download TensorFlow model from: http://tinyclouds.org/colorize/
# 2. Use FFMPEG or such to extract frames from video.
# 3. Make sure your images are 224x224 pixels dimension. You can use imagemagicks "mogrify", here some useful commands:
# mogrify -resize 224x224 *.jpg
# mogrify -gravity center -background black -extent 224x224 *.jpg