Skip to content

Instantly share code, notes, and snippets.

@DanB91
DanB91 / README.txt
Last active November 28, 2022 04:57
Playdate Zig starting point
THIS GIST IS OUT OF DATE! Please use my new project template here to get started with Zig on Playdate:
https://github.com/DanB91/Zig-Playdate-Template
The rest of this is preservied for historical reasons:
This is a small snippet of some code to get you started for developing for the Playdate on Zig. This code should be used as a starting point and may not compile without some massaging. This code has only been tested out on macOS and you'll need to modify the addSharedLibrary() portion of build.zig to output a .dll or .so instead of a .dylib, depending on you platform.
This code will help you produce both an executable for the Playdate simulator and also an executable that actually run on the Playdate hardware.
@mraleph
mraleph / ffi.md
Last active November 11, 2023 14:44

Dart VM FFI Vision

Background

The aim of Dart FFI project (tracked as Issue #34452) is to provide a low boilerplate, low ceremony & low overhead way of interoperating with native C/C++ code.

The motivation behind this project is twofold:

@egmontkob
egmontkob / Hyperlinks_in_Terminal_Emulators.md
Last active May 9, 2024 20:00
Hyperlinks in Terminal Emulators
anonymous
anonymous / GAME_MASTER_v0_1.protobuf
Created July 16, 2016 16:31
Pokemon Go decoded GAME_MASTER protobuf file v0.1
Result: 1
Items {
TemplateId: "BADGE_BATTLE_ATTACK_WON"
Badge {
BadgeType: BADGE_BATTLE_ATTACK_WON
BadgeRanks: 4
Targets: "\nd\350\007"
}
}
Items {
@hako
hako / docx2md.md
Created September 28, 2015 15:59 — forked from carloscasalar/docx2md.md
Convert a Word Document into MD

Converting a Word Document to Markdown in One Move

The Problem

A lot of important government documents are created and saved in Microsoft Word (*.docx). But Microsoft Word is a proprietary format, and it's not really useful for presenting documents on the web. So, I wanted to find a way to convert a .docx file into markdown.

Installing Pandoc

On a mac you can use homebrew by running the command brew install pandoc.

The Solution

/System/Library/AccessibilityBundles/AXSpeechImplementation.bundle/AXSpeechImplementation
/System/Library/AccessibilityBundles/AccessibilitySettingsLoader.bundle/AccessibilitySettingsLoader
/System/Library/AccessibilityBundles/MapKitFramework.axbundle/MapKitFramework
/System/Library/AccessibilityBundles/UIKit.axbundle/UIKit
/System/Library/BulletinBoardPlugins/NanoMailDataProvider.bundle/NanoMailDataProvider
/System/Library/BulletinBoardPlugins/SMSBBPlugin.bundle/SMSBBPlugin
/System/Library/Caches/com.apple.xpc//sdk.dylib
/System/Library/Caches/com.apple.xpcd/xpcd_cache.dylib
/System/Library/CoreServices/Encodings/libArabicConverter.dylib
/System/Library/CoreServices/Encodings/libCyrillicConverter.dylib
@sfan5
sfan5 / image2xterm.py
Last active July 13, 2020 18:24
Converts images into color sequences (xterm-256color)
#!/usr/bin/env python3
import sys
import getopt
from PIL import Image
xterm256colors = [ # http://pln.jonas.me/xterm-colors
(0, (0x00, 0x00, 0x00)), # SYSTEM
(1, (0x80, 0x00, 0x00)), # SYSTEM
(2, (0x00, 0x80, 0x00)), # SYSTEM
(3, (0x80, 0x80, 0x00)), # SYSTEM
@FredericJacobs
FredericJacobs / TrustedSCAPICerts
Created December 17, 2014 09:30
Snapchat Certs (and the Square ones for Snapchat payments)
(
<3082042a 30820312 a0030201 02020438 63def830 0d06092a 864886f7 0d010105 05003081 b4311430 12060355 040a130b 456e7472 7573742e 6e657431 40303e06 0355040b 14377777 772e656e 74727573 742e6e65 742f4350 535f3230 34382069 6e636f72 702e2062 79207265 662e2028 6c696d69 7473206c 6961622e 29312530 23060355 040b131c 28632920 31393939 20456e74 72757374 2e6e6574 204c696d 69746564 31333031 06035504 03132a45 6e747275 73742e6e 65742043 65727469 66696361 74696f6e 20417574 686f7269 74792028 32303438 29301e17 0d393931 32323431 37353035 315a170d 32393037 32343134 31353132 5a3081b4 31143012 06035504 0a130b45 6e747275 73742e6e 65743140 303e0603 55040b14 37777777 2e656e74 72757374 2e6e6574 2f435053 5f323034 3820696e 636f7270 2e206279 20726566 2e20286c 696d6974 73206c69 61622e29 31253023 06035504 0b131c28 63292031 39393920 456e7472 7573742e 6e657420 4c696d69 74656431 33303106 03550403 132a456e 74727573 742e6e65 74204365 72746966 69636174 696f6e20 41757468 6f726974 79202832 30343829 30820122 300d0609 2a864886 f70d0101 01050003 820
@tonymtz
tonymtz / gist:714e73ccb79e21c4fc9c
Created November 15, 2014 00:02
Uninstall XQuartz.app from OSX Yosemite
launchctl unload /Library/LaunchAgents/org.macosforge.xquartz.startx.plist
sudo launchctl unload /Library/LaunchDaemons/org.macosforge.xquartz.privileged_startx.plist
sudo rm -rf /opt/X11* /Library/Launch*/org.macosforge.xquartz.* /Applications/Utilities/XQuartz.app /etc/*paths.d/*XQuartz
sudo pkgutil --forget org.macosforge.xquartz.pkg
# Log out and log in