For anyone running into the Gatekeeper issue on MacOS: https://github.com/deanishe/alfred-booksearch/issues/4#issuecomment-1280097022
TLDR:
Solution: we need to disable gatekeeper for the `alfred-booksearch` binary on the CLI.
xattr -d com.apple.quarantine <path>
Replace <path> with the location of the binary. The binary is located in the workflow folder.
Here’s something you can do in the meantime. First, tell Alfred to not open on startup. Then, copy the following code to the clipboard:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>start_alfred_with_delay</string>
<key>ProgramArguments</key>
<array>
<string>sh</string>
<string>-c</string>
<string>sleep 30 && open -a "Alfred 3"</string>
</array>
<key>RunAtLoad</key>
<true/>
</dict>
</plist>
Open a terminal and run mkdir -p "${HOME}/Library/LaunchAgents" && pbpaste > "${HOME}/Library/LaunchAgents/start_alfred_with_delay.plist".
That’ll make a daemon that will run every time you log on to your machine. It waits for 30 seconds and then opens Alfred. The delay should be enough to solve your case. Change the 30 to another value to tweak the wait.
To undo everything, simply delete the ${HOME}/Library/LaunchAgents/start_alfred_with_delay.plist file.