Skip to content

Commit 6a35400

Browse files
authored
ci: conditionally disable spotlight indexing (#19124)
Work around for following issue: ``` Run sudo mdutil -a -i off sudo mdutil -a -i off sudo mdutil -X / sudo launchctl bootout system /System/Library/LaunchDaemons/com.apple.metadata.mds.plist shell: /bin/bash -e {0} 4 files/directories removed Boot-out failed: 5: Input/output error ``` This can happen if spotlight has already been disabled.
1 parent 6ba4b5b commit 6a35400

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.github/workflows/ci.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -340,6 +340,11 @@ jobs:
340340
- name: Disable Spotlight Indexing
341341
if: runner.os == 'macOS'
342342
run: |
343+
enabled=$(sudo mdutil -a -s | grep "Indexing enabled" | wc -l)
344+
if [ $enabled -eq 0 ]; then
345+
echo "Spotlight indexing is already disabled"
346+
exit 0
347+
fi
343348
sudo mdutil -a -i off
344349
sudo mdutil -X /
345350
sudo launchctl bootout system /System/Library/LaunchDaemons/com.apple.metadata.mds.plist

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy