Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 17 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ Whisper supports up to 99 languages, depending on the model size you choose.
- Intel Macs are supported from 1.5.1 builds using Whisper models!
- Microphone access
- Accessibility permissions for typing
- Cohere Transcribe and Qwen3 ASR require macOS 15.0 or later


## Join our small community to help us grow and give feedback :) ( Or just hang?!)
Expand All @@ -134,6 +135,20 @@ open Fluid.xcodeproj

Build and run in Xcode. All dependencies are managed via Swift Package Manager.

### Build Output Location and Launch

If you use the provided scripts, the app bundle is written directly into ./build/

Build and launch examples:

```bash
./build.sh dev # Debug build to ./build
./build.sh release # Release build to ./build
./build.sh -l dev # Build and launch
./build.sh -i -l release # Build, install to /Applications, then launch
open -n "$PWD/build/FluidVoice Debug.app"
```

## Contributing

Contributions are welcome! Please create an issue first to discuss any major changes or feature requests before submitting a pull request.
Expand Down Expand Up @@ -161,7 +176,8 @@ Contributions are welcome! Please create an issue first to discuss any major cha

5. **Build only (no signing):**
```bash
xcodebuild -project Fluid.xcodeproj -scheme Fluid -destination 'platform=macOS' build CODE_SIGNING_ALLOWED=NO
./build.sh dev
./build.sh release
```

5. **(Optional) Install pre-commit hook** to prevent accidental team ID commits:
Expand Down
120 changes: 103 additions & 17 deletions build.sh
Original file line number Diff line number Diff line change
@@ -1,30 +1,116 @@
#!/bin/bash

# FluidVoice Build Profile Router
# Routes to existing scripts without changing build_dev.sh behavior.
#
# Usage:
# ./build.sh # dev/full-compatible path (build_dev.sh)
# ./build.sh dev # same as above
# ./build.sh full # same as above
# ./build.sh incremental # fast local loop (build_incremental.sh)
# BUILD_PROFILE=incremental ./build.sh

set -euo pipefail

PROJECT_DIR="$(cd "$(dirname "$0")" && pwd)"
PROFILE="${1:-${BUILD_PROFILE:-dev}}"
PROJECT_FILE="${PROJECT_DIR}/Fluid.xcodeproj"
SCHEME="Fluid"
DESTINATION="platform=macOS"
BUILD_DIR="${PROJECT_DIR}/build"

usage() {
echo "Usage: ./build.new.sh [-i] [-l] [dev|release|clean]"
echo "Options:"
echo " -i Install built app into /Applications"
echo " -l Launch app after build (or after install if -i is set)"
echo "Profiles:"
echo " dev Debug, incremental build for development"
echo " release Optimized build for production/release"
echo " clean Delete generated build artifacts"
}

INSTALL_APP=0
LAUNCH_APP=0
PROFILE=""

while [[ $# -gt 0 ]]; do
case "$1" in
-i)
INSTALL_APP=1
;;
-l)
LAUNCH_APP=1
;;
-h|--help)
usage
exit 0
;;
dev|release|clean)
if [[ -n "${PROFILE}" ]]; then
echo "Only one profile may be provided."
usage
exit 1
fi
PROFILE="$1"
;;
*)
echo "Unknown argument: $1"
usage
exit 1
;;
esac
shift
done

if [[ -z "${PROFILE}" ]]; then
usage
exit 1
fi

case "${PROFILE}" in
dev|full)
exec "${PROJECT_DIR}/build_dev.sh"
dev)
CONFIGURATION="Debug"
SWIFT_COMPILATION_MODE="incremental"
;;
release)
CONFIGURATION="Release"
SWIFT_COMPILATION_MODE="wholemodule"
;;
incremental|fast)
exec "${PROJECT_DIR}/build_incremental.sh"
clean)
rm -rf "${BUILD_DIR}"
echo "Deleted build artifacts: ${BUILD_DIR}"
exit 0
;;
*)
echo "Unknown build profile: ${PROFILE}"
echo "Valid profiles: dev, full, incremental (or fast)"
echo "Unknown profile: ${PROFILE}"
echo "Valid profiles: dev, release, clean"
exit 1
;;
esac

CODE_SIGNING_ALLOWED="${CODE_SIGNING_ALLOWED:-NO}"
CODE_SIGNING_REQUIRED="${CODE_SIGNING_REQUIRED:-NO}"

mkdir -p "${BUILD_DIR}"

xcodebuild \
-project "${PROJECT_FILE}" \
-scheme "${SCHEME}" \
-configuration "${CONFIGURATION}" \
-destination "${DESTINATION}" \
build \
CONFIGURATION_BUILD_DIR="${BUILD_DIR}" \
SWIFT_COMPILATION_MODE="${SWIFT_COMPILATION_MODE}" \
CODE_SIGNING_ALLOWED="${CODE_SIGNING_ALLOWED}" \
CODE_SIGNING_REQUIRED="${CODE_SIGNING_REQUIRED}"

if [[ "${CONFIGURATION}" == "Debug" ]]; then
APP_PATH="${BUILD_DIR}/FluidVoice Debug.app"
else
APP_PATH="${BUILD_DIR}/FluidVoice.app"
fi

echo "App bundle: ${APP_PATH}"

if [[ "${INSTALL_APP}" == "1" ]]; then
APP_NAME="$(basename "${APP_PATH}")"
INSTALL_PATH="/Applications/${APP_NAME}"
rsync -a --delete "${APP_PATH}/" "${INSTALL_PATH}/"
APP_PATH="${INSTALL_PATH}"
echo "Installed app bundle: ${APP_PATH}"
fi

if [[ "${LAUNCH_APP}" == "1" ]]; then
open -n "${APP_PATH}"
echo "Launched app bundle: ${APP_PATH}"
fi
22 changes: 0 additions & 22 deletions build_incremental.sh

This file was deleted.

Loading