Skip to content

Instantly share code, notes, and snippets.

@gfreezy
gfreezy / migrate.sh
Last active August 30, 2025 13:25
Hacking native ARM64 binaries to run on the iOS Simulator
#!/usr/bin/env bash
set -ex
# https://bogo.wtf/arm64-to-sim.html
ios_plat=ios
simulator_plat=simulator
make() {
for name in $@; do
@gfreezy
gfreezy / sync-xcode-preview.py
Last active September 23, 2022 14:56
Copy privileges from simulator to xcode preview & copy photos from simulator to preview
"""
Use the following code in xcode preview to get the simulator path. Xcode preview does not support print or log to console.
So you need to use a `Text` view to show the path.
`
NSSearchPathForDirectoriesInDomains(FileManager.SearchPathDirectory.applicationSupportDirectory, .userDomainMask, true)
`
"""
import pathlib
import subprocess
@gfreezy
gfreezy / RecordingView.swift
Created October 29, 2025 06:26 — forked from wangcheng/RecordingView.swift
RecordingView.swift
//
// RecordingView.swift
// voicekeyboard
//
// Informational view shown when app is launched via voicekeyboard://record
// Pure UI component - business logic handled in voicekeyboardApp.handleRecognitionRequest
//
import SwiftUI