Contributing to SketchyBar

Contributions are welcome! Whether you're fixing a bug, adding a feature, or improving documentation, your help is appreciated.

Development Setup

To get started with development, you'll need to compile the project from source. The primary tool for this is the provided makefile.

Prerequisites

  • Xcode Command Line Tools: Ensure you have make, cc (Clang), and other build essentials installed. You can install them with xcode-select --install.

Building the Project

The makefile includes several targets for different development needs:

  • make or make all or make universal: Builds a universal binary for both x86_64 (Intel) and arm64 (Apple Silicon) architectures. This is the standard build for distribution.

  • make x86: Compiles only the x86_64 version.

  • make arm64: Compiles only the arm64 version.

  • make debug: Compiles an arm64 binary with debug symbols (-g), making it suitable for use with a debugger like lldb.

  • make asan: Compiles with AddressSanitizer and UndefinedBehaviorSanitizer enabled. This is extremely useful for catching memory errors and other undefined behavior during testing.

  • make leak: Compiles a debug build and runs it with the leaks tool to check for memory leaks at exit.

  • make clean: Removes all compiled binaries and object files from the bin/ directory.

Code of Conduct

Please be respectful and constructive in all your interactions within the project community.

Submitting Changes

  1. Fork the repository on GitHub.
  2. Create a new branch for your feature or bug fix.
  3. Make your changes. Adhere to the existing code style.
  4. Test your changes thoroughly. Use the debug and asan build targets to catch potential issues.
  5. Submit a pull request with a clear description of the changes you have made and the problem they solve.

License

By contributing, you agree that your contributions will be licensed under the GNU General Public License v3.0, the same license that covers the project. You can find the full license text in the LICENSE file.