Skip to content

Instantly share code, notes, and snippets.

@moshe-foreflight
moshe-foreflight / cdb.sh
Created March 15, 2024 21:51
Build a compilation database from Xcodebuild.
#!/usr/bin/env bash
scheme=""
root=""
cd "${HOME}/${root}" || exit;
if [ -z "$1" ] || [ "$1" == "clean" ];
then
rm -rf /tmp/cdb # could use some other path, or uniquify the folder name, but this is easy