From e6982b885b9734b13ccbab9e76983288b26e65f1 Mon Sep 17 00:00:00 2001 From: hjmmc Date: Sun, 7 Jun 2020 19:19:30 +0800 Subject: [PATCH] Fix #28 --- HDMIFix/README.md | 39 --------------------- HDMIFix/com.magicbokk.displaysleepnow.plist | 14 -------- HDMIFix/com.magicbokk.displaysleepnow.sh | 5 --- HDMIFix/install.command | 15 -------- HDMIFix/uninstall.command | 8 ----- 5 files changed, 81 deletions(-) delete mode 100644 HDMIFix/README.md delete mode 100644 HDMIFix/com.magicbokk.displaysleepnow.plist delete mode 100755 HDMIFix/com.magicbokk.displaysleepnow.sh delete mode 100755 HDMIFix/install.command delete mode 100755 HDMIFix/uninstall.command diff --git a/HDMIFix/README.md b/HDMIFix/README.md deleted file mode 100644 index 6b7d434..0000000 --- a/HDMIFix/README.md +++ /dev/null @@ -1,39 +0,0 @@ -# Fix HDMI issue just after startup - -This script is mainly to solve the problem that `the built-in screen has been not turned off after booting`, black screen and system stuck will caused by the HDMI connection. - -## Specific performance: - -- 1.The built-in screen has not been turned off, system will stuck when connected to the HDMI. -- 2.The built-in screen has not been turned off, black screen immediately after connecting to HDMI, you need to restart -- 3.The built-in screen has not been turned off, black screen after connecting to HDMI and unplugging. You need to wait for a while to recover or restart - -If you have the above problems, you can try to install this script. The script function is mainly to use the command to automatically turn off and light the built-in screen after booting. - -## Install - -Double-click `install.command` - -## Uninstall - -Double-click `uninstall.command` - -## 中文说明 - -这个脚本主要是为了解决系统启动后`未熄灭过内建屏幕`接入HDMI会造成黑屏卡顿的问题 - -## 具体表现: - -- 1.未熄灭过内建屏幕,接入HDMI系统卡顿 -- 2.未熄灭过内建屏幕,接入HDMI立马黑屏,需要重启 -- 3.未熄灭过内建屏幕,接入HDMI拔出后黑屏,需要等待一段时间恢复或需要重启 - -有以上问题的可以尝试安装这个脚本,脚本功能主要是在开机后使用命令自动熄灭和点亮内建屏幕 - -## 安装 - -双击 `install.command` - -## 卸载 - -双击 `uninstall.command` \ No newline at end of file diff --git a/HDMIFix/com.magicbokk.displaysleepnow.plist b/HDMIFix/com.magicbokk.displaysleepnow.plist deleted file mode 100644 index 04d64ad..0000000 --- a/HDMIFix/com.magicbokk.displaysleepnow.plist +++ /dev/null @@ -1,14 +0,0 @@ - - - - - Label - com.magicbokk.displaysleepnow - ProgramArguments - - /Library/LaunchDaemons/com.magicbokk.displaysleepnow.sh - - RunAtLoad - - - \ No newline at end of file diff --git a/HDMIFix/com.magicbokk.displaysleepnow.sh b/HDMIFix/com.magicbokk.displaysleepnow.sh deleted file mode 100755 index 7ed2d52..0000000 --- a/HDMIFix/com.magicbokk.displaysleepnow.sh +++ /dev/null @@ -1,5 +0,0 @@ -#!/bin/bash -sleep 3s -pmset displaysleepnow -sleep 1s -caffeinate -u -t 1 \ No newline at end of file diff --git a/HDMIFix/install.command b/HDMIFix/install.command deleted file mode 100755 index 7e0cdcc..0000000 --- a/HDMIFix/install.command +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash - -DIR="$( cd "$( dirname "$0" )" && pwd )" - -echo $DIR - -#copy -sudo cp $DIR/com.magicbokk.displaysleepnow.sh /Library/LaunchDaemons/ -sudo cp $DIR/com.magicbokk.displaysleepnow.plist /Library/LaunchDaemons/ -# chmod -sudo chmod +x /Library/LaunchDaemons/com.magicbokk.displaysleepnow.sh -# load -sudo launchctl load -w /Library/LaunchDaemons/com.magicbokk.displaysleepnow.plist - -echo 'Install Successed!' \ No newline at end of file diff --git a/HDMIFix/uninstall.command b/HDMIFix/uninstall.command deleted file mode 100755 index e27fbd6..0000000 --- a/HDMIFix/uninstall.command +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash - -# unload -sudo launchctl unload -w /Library/LaunchDaemons/com.magicbokk.displaysleepnow.plist -# delete -sudo rm -rf /Library/LaunchDaemons/com.magicbokk.displaysleepnow.* - -echo 'Unistall Successed!' \ No newline at end of file