Rename bundle id to com.mmacierzanka.second-display; drop legacy names from scripts

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
mmacierzankaandClaude Bot committed 2026-11-03 14:05:45 +01:00
1 parent d3609ae29c
commit d61098de7d
6 files changed
+9 -10

No files matched your search

+1 -1
View File
@@ -16,7 +16,7 @@ A native macOS app that shows video from a capture device (camera / capture card
- `Sources/` – app code (AppKit + AVFoundation, one `AVCaptureSession`, audio via `AVCaptureAudioPreviewOutput`). The `App` class is split into extensions:
`main.swift` (entry point), `App.swift` (state, window, lifecycle), `Capture.swift` (devices, formats, hot-plug), `Menu.swift` (menus and actions), `Power.swift` (sleep prevention), `Autostart.swift` (launch-on-connect agent), `Preferences.swift` (UserDefaults-backed settings).
- `Config/Info.plist`, `Config/second-display.entitlements`, `Config/dmg/` – version, permissions (camera, microphone; hardened runtime).
- `Resources/` – `AppIcon.icon` (Icon Composer, Liquid Glass; compiled by `actool`), `{en,pl}.lproj` (`Localizable.strings`, `InfoPlist.strings`), `uninstall.sh` (copied into the bundle; removes the app, preferences, caches, TCC permissions). Bundle ID: `com.mmacierzanka.seconddisplay`.
- `Resources/` – `AppIcon.icon` (Icon Composer, Liquid Glass; compiled by `actool`), `{en,pl}.lproj` (`Localizable.strings`, `InfoPlist.strings`), `uninstall.sh` (copied into the bundle; removes the app, preferences, caches, TCC permissions). Bundle ID: `com.mmacierzanka.second-display`.
- `scripts/check-strings.sh` – en/pl translation consistency. `scripts/make-dmg-background.swift` regenerates `Config/dmg/background.png`; keep its size and icon coordinates in sync with `Config/dmg/settings.py` (dmgbuild layout, installed into `build/venv` on first `make dmg`).
- `Makefile` – `make` (builds `build/Second Display.app`), `run`, `check`, `install`, `uninstall`, `dmg`, `clean`, `help`. Builds are universal (arm64 + x86_64, macOS 26+). `make dmg` makes an un-notarized DMG with `Config/dmg/Read Me First.txt`. `SIGN_ID` defaults to ad-hoc (`-`).
+1 -1
View File
@@ -5,7 +5,7 @@
<key>CFBundleDevelopmentRegion</key><string>en</string>
<key>CFBundleLocalizations</key><array><string>en</string><string>pl</string></array>
<key>CFBundleExecutable</key><string>Second Display</string>
<key>CFBundleIdentifier</key><string>com.mmacierzanka.seconddisplay</string>
<key>CFBundleIdentifier</key><string>com.mmacierzanka.second-display</string>
<key>CFBundleName</key><string>Second Display</string>
<key>CFBundlePackageType</key><string>APPL</string>
<key>CFBundleShortVersionString</key><string>0.1.0</string>
+1 -1
View File
@@ -37,7 +37,7 @@ clean: ## Remove build output
rm -rf build
install: build ## Copy to ~/Applications
mkdir -p ~/Applications && rm -rf ~/Applications/SecondDisplay.app "$$HOME/Applications/$(NAME).app" && cp -R "$(APP)" ~/Applications/
mkdir -p ~/Applications && rm -rf "$$HOME/Applications/$(NAME).app" && cp -R "$(APP)" ~/Applications/
uninstall: ## Remove the installed app and all its leftovers
"$$HOME/Applications/$(NAME).app/Contents/Resources/uninstall.sh"
+2 -2
View File
@@ -34,7 +34,7 @@ If you received a prebuilt copy (the `.dmg`), drag the app to Applications. It i
## Usage
Menus at the top of the screen: **Video** (device, format), **Audio** (source or off), **Options** (prevent display sleep, start in full screen, always on top, mute ⇧⌘M, scaling), **Window** (tiling, full screen ⌃⌘F).
**Autostart** opens the app whenever the chosen USB capture device is plugged in (and makes it the active video source). It installs a per-user LaunchAgent (`~/Library/LaunchAgents/com.mmacierzanka.seconddisplay.autostart.plist`) matching the device's USB vendor/product ID, so only USB (UVC) devices can be chosen. Choose **Off** to remove it; the uninstall script removes it too.
**Autostart** opens the app whenever the chosen USB capture device is plugged in (and makes it the active video source). It installs a per-user LaunchAgent (`~/Library/LaunchAgents/com.mmacierzanka.second-display.autostart.plist`) matching the device's USB vendor/product ID, so only USB (UVC) devices can be chosen. Choose **Off** to remove it; the uninstall script removes it too.
## Layout
- `Sources/` – the app (AppKit + AVFoundation): `App` (state, window), `Capture` (devices, formats), `Menu`, `Power`, `Preferences`, `main` (entry point)
@@ -43,7 +43,7 @@ Menus at the top of the screen: **Video** (device, format), **Audio** (source or
- `scripts/check-strings.sh` – translation consistency
## Settings and uninstall
Settings: `~/Library/Preferences/com.mmacierzanka.seconddisplay.plist`.
Settings: `~/Library/Preferences/com.mmacierzanka.second-display.plist`.
To remove the app and all its traces: `make uninstall` or `"Second Display.app/Contents/Resources/uninstall.sh"`.
## License
+3 -4
View File
@@ -1,18 +1,17 @@
#!/bin/zsh
# Removes Second Display and everything it leaves behind. Usage: run from inside the app bundle.
ID=com.mmacierzanka.seconddisplay
ID=com.mmacierzanka.second-display
APP="${0:A:h:h:h}"
[[ "$APP" == *.app && "$(defaults read "$APP/Contents/Info" CFBundleIdentifier 2>/dev/null)" == "$ID" ]] || { echo "Not a Second Display bundle: $APP"; exit 1; }
read -q "?Delete $APP and all its data? [y/N] " || { echo; echo Cancelled; exit 0; }
echo
pkill -x "Second Display" 2>/dev/null; pkill -x SecondDisplay 2>/dev/null # current and legacy executable names
pkill -x "Second Display" 2>/dev/null
launchctl bootout "gui/$(id -u)/$ID.autostart" 2>/dev/null # launch-on-connect agent
rm -f ~/Library/LaunchAgents/$ID.autostart.plist
defaults delete "$ID" 2>/dev/null
tccutil reset All "$ID" >/dev/null 2>&1 # camera / microphone permissions
L=~/Library
rm -rf "$L/Preferences/$ID.plist" "$L/Caches/$ID" "$L/HTTPStorages/$ID" "$L/Saved Application State/$ID.savedState" \
"$L/Application Support/$ID" "$L/Containers/$ID" "$L/WebKit/$ID" "$L/Logs/$ID"
rm -rf "$L/Preferences/$ID.plist" "$L/Caches/$ID" "$L/Saved Application State/$ID.savedState"
killall cfprefsd 2>/dev/null
echo "Removed. Deleting $APP"
rm -rf "$APP"
+1 -1
View File
@@ -3,7 +3,7 @@ import AVFoundation
// Launch-on-connect: a per-user LaunchAgent that opens the app when the chosen USB device is attached.
extension App {
static let agentLabel = "com.mmacierzanka.seconddisplay.autostart"
static let agentLabel = "com.mmacierzanka.second-display.autostart"
var agentURL: URL {
FileManager.default.homeDirectoryForCurrentUser.appendingPathComponent("Library/LaunchAgents/\(Self.agentLabel).plist")
}