Browse Source
fix: unknown parameter`xattr -r` on newer MacOS versions
Signed-off-by: Teo <teocns@gmail.com>
pull/560/head
Teo
1 day ago
No known key found for this signature in database
GPG Key ID: 3B76E29DA2B5AF4A
2 changed files with
5 additions and
2 deletions
-
scripts/run/cursor_mac_free_trial_reset.sh
-
scripts/run/cursor_mac_id_modifier.sh
|
@ -1161,7 +1161,8 @@ fix_damaged_app() { |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
log_info "尝试移除隔离属性..." |
|
|
log_info "尝试移除隔离属性..." |
|
|
if sudo xattr -rd com.apple.quarantine "$CURSOR_APP_PATH" 2>/dev/null; then |
|
|
|
|
|
|
|
|
if sudo find "$CURSOR_APP_PATH" -print0 \ |
|
|
|
|
|
| xargs -0 sudo xattr -d com.apple.quarantine 2>/dev/null |
|
|
log_info "成功移除隔离属性" |
|
|
log_info "成功移除隔离属性" |
|
|
else |
|
|
else |
|
|
log_warn "移除隔离属性失败,尝试其他方法..." |
|
|
log_warn "移除隔离属性失败,尝试其他方法..." |
|
|
|
@ -2734,7 +2734,9 @@ fix_damaged_app() { |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
log_info "尝试移除隔离属性..." |
|
|
log_info "尝试移除隔离属性..." |
|
|
if sudo xattr -rd com.apple.quarantine "$CURSOR_APP_PATH" 2>/dev/null; then |
|
|
|
|
|
|
|
|
if sudo find "$CURSOR_APP_PATH" -print0 \ |
|
|
|
|
|
| xargs -0 sudo xattr -d com.apple.quarantine 2>/dev/null |
|
|
|
|
|
then |
|
|
log_info "成功移除隔离属性" |
|
|
log_info "成功移除隔离属性" |
|
|
else |
|
|
else |
|
|
log_warn "移除隔离属性失败,尝试其他方法..." |
|
|
log_warn "移除隔离属性失败,尝试其他方法..." |
|
|