Generate searchable private headers from this Mac or an installed iOS or watchOS Simulator runtime.
Requires macOS 14 or later. Prebuilt releases require Apple Silicon. iOS and watchOS generation require Xcode and a matching installed Simulator runtime; physical devices are not generation sources. Source installation requires Swift 6.3 and Xcode with iOS and watchOS Simulator SDKs.
curl -fsSLO https://github.com/lynnswap/PrivateHeaderKit/releases/latest/download/install.sh && sh ./install.shIf the installer prints a Next steps block, follow it instead of the command
below. Otherwise run:
privateheaderkitChoose a source, then generate all targets or enter specific framework, bundle,
or dylib names. PrivateHeaderKit writes to ~/PrivateHeaderKit by default and
prints the exact Headers directory for the generated files.
Generated headers are grouped by platform and exact source, for example
generated-headers/iOS/27.0_beta_24A5390f.
The installer does not edit shell profiles.
Build and run the source installer from the checkout:
git clone https://github.com/lynnswap/PrivateHeaderKit.git
cd PrivateHeaderKit
swift run -c release privateheaderkit-installThe installer builds privateheaderkit and three internal helpers from the same
checkout. It accepts the same --prefix and --bindir options as install.sh.
Custom directories
Install the command in ~/bin:
curl -fsSLO https://github.com/lynnswap/PrivateHeaderKit/releases/latest/download/install.sh && sh ./install.sh --bindir ~/binThe no-argument command is the recommended interactive path. For scripts, pass all generation inputs explicitly:
privateheaderkit \
--platform macOS \
--version "$(sw_vers -productVersion)" \
--build "$(sw_vers -buildVersion)" \
--system-root / \
--out ~/PrivateHeaderKit \
--target AppKit,Foundationprivateheaderkit \
--platform iOS \
--version 27.0 \
--out ~/PrivateHeaderKit \
--target SwiftUI,UIKitprivateheaderkit \
--platform watchOS \
--version 27.0 \
--out ~/PrivateHeaderKit \
--target WatchKitUse privateheaderkit --help for the complete option list. Replace each example
version with an installed runtime version. If more than one runtime for the
selected platform matches a version, add --build <build>.
- Installation and updates
- Generation, output, and resume behavior
- Troubleshooting
- Development and releases
PrivateHeaderKit is available under the MIT License.