Overview
iSH is an open-source project that welcomes contributions from the community. Whether you’re fixing bugs, adding features, improving documentation, or reporting issues, your contributions help make iSH better for everyone.iSH is available on GitHub and uses Git submodules, so make sure to clone with
--recurse-submodules or run git submodule update --init after cloning.Getting Started
Set up your development environment
First, ensure you have all the required dependencies installed:Required tools:
- Python 3 with Meson (
pip3 install meson) - Ninja build system
- Clang and LLD compiler/linker
- macOS:
brew install llvm - Debian/Ubuntu:
sudo apt install clang lld - Arch Linux:
sudo pacman -S clang lld
- macOS:
- sqlite3 (usually pre-installed)
- libarchive
- macOS:
brew install libarchiveorsudo port install libarchive - Debian/Ubuntu:
sudo apt install libarchive-dev
- macOS:
Clone the repository
Clone the iSH repository with submodules:If you already cloned without submodules:
Build and test
Build the project to ensure everything is working:For iOS (Xcode):Test your build to ensure it works correctly before making changes.
- Open the project in Xcode
- Open
iSH.xcconfigand changeROOT_BUNDLE_IDENTIFIERto something unique - Update the development team ID in the project build settings
- Click Run
Make your changes
Create a new branch for your work:Make your changes following the project’s code conventions (see below).
Test thoroughly
Before submitting, test your changes:
- Build and run the iOS app or CLI tool
- Test the specific functionality you modified
- Enable logging channels to debug (see Logging & Debugging)
- Run
dmesgfor system call errors if applicable
Code Style and Conventions
General Guidelines
- Follow the existing code style in the file you’re editing
- Keep changes focused and atomic - one logical change per PR
- Write clear commit messages that explain the “why” not just the “what”
- Comment complex logic, especially in the emulator core
Assembly Code
The assembly code uses threaded code technique with function pointers (gadgets). See the Interpreter page for background.Logging
When adding debug logging, use the appropriate channel:strace- System call parameters and return valuesinstr- Individual instruction execution (very verbose)verbose- General debug information
Reporting Issues
Before opening an issue, check the existing issues and commit logs for current project status.Bug Reports
When reporting bugs, include:For crashes
For crashes
Include a crash dump from your device:
- iOS 12+: Settings → Privacy → Analytics → Analytics Data
- iOS 11: Settings → Privacy → Diagnostics and Usage
For system call errors
For system call errors
If you see errors like:
- “Bad system call”
- “Illegal instruction”
- “Segmentation fault”
dmesg in iSH to get log messages and include the relevant output in your issue.General information
General information
For all bug reports, include:
- Steps to reproduce the issue
- Expected vs. actual behavior
- iSH version (App Store or TestFlight build number)
- iOS version
- Device model
Feature Requests
For feature requests:- Explain the use case and why it would be valuable
- Consider technical feasibility within iOS constraints
- Check if it’s already been discussed in issues or on Discord
Documentation Contributions
Documentation improvements are always welcome:- Fix typos, unclear explanations, or outdated information
- Add examples and use cases
- Expand on technical concepts
- Improve organization and navigation
Testing and Validation
Unit Testing
While iSH doesn’t have extensive automated tests, you should manually test:- System calls - Verify your changes don’t break existing syscalls
- Emulation - Test with real programs (compilers, interpreters, utilities)
- Edge cases - Try unusual inputs and error conditions
- Performance - Check that changes don’t significantly impact speed
Debugging Tools
ptraceomatic for instruction-level debugging
ptraceomatic for instruction-level debugging
On 64-bit Linux 4.11+, use This runs the program in a real process and single-steps to compare registers at each step, useful for debugging emulation issues.
tools/ptraceomatic instead of ish to run programs:Logging Channels
Enable logging to understand what’s happening: Xcode:Code Review Process
- Automated checks - CI builds must pass
- Maintainer review - A project maintainer will review your code
- Discussion - Be responsive to feedback and questions
- Iteration - Make requested changes and push updates
- Merge - Once approved, your PR will be merged
Community Guidelines
- Be respectful and constructive in all interactions
- Help others when you can
- Focus on technical merit of ideas
- Understand that not all contributions can be accepted
- iOS limitations may prevent certain features from being feasible
Getting Help
If you need help contributing:- Join the Discord server and ask in the development channels
- Check the Wiki for tutorials and guides
- Look at recent commits and PRs for examples
- Read the FAQ for common questions
Next Steps
Build for iOS
Set up Xcode and build iSH for your iOS device
Build CLI Tool
Build the command-line testing tool
Architecture
Understand how iSH works internally
Interpreter
Learn about the threaded code interpreter