-
-
Save zhangcheng/c4fde15d589e3be9a9c2705645716f40 to your computer and use it in GitHub Desktop.
Revisions
-
santaklouse revised this gist
Oct 18, 2023 . 1 changed file with 26 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,26 @@ #!/usr/bin/env bash # find app in default paths CO_PWD=~/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || CO_PWD=/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || (echo 'unable to detect app path. exiting...' && exit) PWD="${CO_PWD}" cd "${PWD}" PROC_NAME='CrossOver' # get all pids of CrossOver pids=(`pgrep "${PROC_NAME}"`, `pidof "${PROC_NAME}"`, `ps -Ac | grep -m1 "${PROC_NAME}" | awk '{print $1}'`) pids=`echo ${pids[*]}|tr ',' ' '` # kills CrossOver process if it is running [ "${pids}" ] && kill -9 `echo "${pids}"` > /dev/null 2>&1 if [ -f CrossOver.origin ]; then echo 'original file found. Roll it back and exit.' mv CrossOver.origin CrossOver exit fi; echo 'original file not found.' -
santaklouse revised this gist
Sep 19, 2023 . 1 changed file with 1 addition and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,6 +9,7 @@ test -d "${CO_PWD}" || (echo 'unable to detect app path. exiting...' && exit) PWD="${CO_PWD}" cd "${PWD}" PROC_NAME='CrossOver' # get all pids of CrossOver pids=(`pgrep "${PROC_NAME}"`, `pidof "${PROC_NAME}"`, `ps -Ac | grep -m1 "${PROC_NAME}" | awk '{print $1}'`) pids=`echo ${pids[*]}|tr ',' ' '` -
santaklouse revised this gist
Sep 19, 2023 . 2 changed files with 9 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,6 +9,8 @@ PIDOF="$(which pidof)" CO_PWD=~/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || CO_PWD=/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || (echo 'unable to detect app path. exiting...' && exit) PWD="${CO_PWD}" cd "${PWD}" This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,6 +9,13 @@ test -d "${CO_PWD}" || (echo 'unable to detect app path. exiting...' && exit) PWD="${CO_PWD}" cd "${PWD}" # get all pids of CrossOver pids=(`pgrep "${PROC_NAME}"`, `pidof "${PROC_NAME}"`, `ps -Ac | grep -m1 "${PROC_NAME}" | awk '{print $1}'`) pids=`echo ${pids[*]}|tr ',' ' '` # kills CrossOver process if it is running [ "${pids}" ] && kill -9 `echo "${pids}"` > /dev/null 2>&1 TIMESTAMP=$(date +%s) FIX_FILE_LINK="https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/CrossOver.sh?token=${TIMESTAMP}" -
santaklouse revised this gist
Sep 19, 2023 . 1 changed file with 0 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -12,7 +12,6 @@ cd "${PWD}" TIMESTAMP=$(date +%s) FIX_FILE_LINK="https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/CrossOver.sh?token=${TIMESTAMP}" if [ -f CrossOver.origin ]; then echo 'already installed. update and exit.' echo "$(curl -fsSL ${FIX_FILE_LINK})" > CrossOver -
santaklouse revised this gist
Sep 19, 2023 . 1 changed file with 5 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -13,6 +13,11 @@ TIMESTAMP=$(date +%s) FIX_FILE_LINK="https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/CrossOver.sh?token=${TIMESTAMP}" test -f CrossOver.origin && echo 'already installed. exiting...' && exit if [ -f CrossOver.origin ]; then echo 'already installed. update and exit.' echo "$(curl -fsSL ${FIX_FILE_LINK})" > CrossOver exit fi; test -f CrossOver.origin || mv CrossOver CrossOver.origin -
santaklouse revised this gist
Sep 19, 2023 . 2 changed files with 4 additions and 3 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ ## Run it in console for permanent install : ``` bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/install.sh?token=$(date +%s))" ``` After install script will fix crossover as well as expired bottles (Thanks to @djsmax). This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -9,13 +9,14 @@ test -d "${CO_PWD}" || (echo 'unable to detect app path. exiting...' && exit) PWD="${CO_PWD}" cd "${PWD}" TIMESTAMP=$(date +%s) FIX_FILE_LINK="https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/CrossOver.sh?token=${TIMESTAMP}" test -f CrossOver.origin && echo 'already installed. exiting...' && exit test -f CrossOver.origin || mv CrossOver CrossOver.origin echo "$(curl -fsSL ${FIX_FILE_LINK})" > CrossOver chmod +x CrossOver -
santaklouse revised this gist
Sep 19, 2023 . 3 changed files with 37 additions and 16 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,28 +1,42 @@ #!/usr/bin/env bash # checck if pidof exists PIDOF="$(which pidof)" # and if not - install it (test "${PIDOF}" && test -f "${PIDOF}") || brew install pidof # find app in default paths CO_PWD=~/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || CO_PWD=/Applications/CrossOver.app/Contents/MacOS PWD="${CO_PWD}" cd "${PWD}" PROC_NAME='CrossOver' # get all pids of CrossOver pids=(`pgrep "${PROC_NAME}"`, `pidof "${PROC_NAME}"`, `ps -Ac | grep -m1 "${PROC_NAME}" | awk '{print $1}'`) pids=`echo ${pids[*]}|tr ',' ' '` # kills CrossOver process if it is running [ "${pids}" ] && kill -9 `echo "${pids}"` > /dev/null 2>&1 # wait until app finish sleep 3 # make the current date RFC3339-encoded string representation in UTC time zone DATETIME=`date -u -v -3H '+%Y-%m-%dT%TZ'` # modify time in order to reset trial plutil -replace FirstRunDate -date "${DATETIME}" ~/Library/Preferences/com.codeweavers.CrossOver.plist plutil -replace SULastCheckTime -date "${DATETIME}" ~/Library/Preferences/com.codeweavers.CrossOver.plist # show tooltip notification /usr/bin/osascript -e "display notification \"trial fixed: date changed to ${DATETIME}\"" # reset all bottles for file in ~/Library/Application\ Support/CrossOver/Bottles/*/.{eval,update-timestamp}; do rm -rf "${file}";done # and after this execute original crossover echo "${PWD}" > /tmp/co_log.log "$($PWD/CrossOver.origin)" >> /tmp/co_log.log This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ ## Run it in console for permanent install : ``` bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/install.sh)" ``` After install script will fix crossover as well as expired bottles (Thanks to @djsmax). This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,8 +1,15 @@ #!/usr/bin/env bash # find app in default paths CO_PWD=~/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || CO_PWD=/Applications/CrossOver.app/Contents/MacOS test -d "${CO_PWD}" || (echo 'unable to detect app path. exiting...' && exit) PWD="${CO_PWD}" cd "${PWD}" FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/CrossOver.sh' test -f CrossOver.origin && echo 'already installed. exiting...' && exit -
santaklouse revised this gist
Jul 13, 2023 . 2 changed files with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ ## Run it in console for permanent install : ``` bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/a9cfd03a04e8afc7e907e38c0fb02042e0ab143e/install.sh)" ``` After install script will fix crossover as well as expired bottles (Thanks to @djsmax). This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ cd /Applications/CrossOver.app/Contents/MacOS/ FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/a9cfd03a04e8afc7e907e38c0fb02042e0ab143e/CrossOver.sh' test -f CrossOver.origin && echo 'already installed. exiting...' && exit -
santaklouse revised this gist
Jul 13, 2023 . 1 changed file with 0 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -8,8 +8,6 @@ test -f CrossOver.origin && echo 'already installed. exiting...' && exit test -f CrossOver.origin || mv CrossOver CrossOver.origin echo "$(curl -fsSL $FIX_FILE_LINK)" > CrossOver chmod +x CrossOver -
santaklouse revised this gist
Jul 13, 2023 . 1 changed file with 2 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,6 +6,8 @@ FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed6 test -f CrossOver.origin && echo 'already installed. exiting...' && exit test -f CrossOver.origin || mv CrossOver CrossOver.origin mv CrossOver CrossOver.origin echo "$(curl -fsSL $FIX_FILE_LINK)" > CrossOver -
santaklouse revised this gist
Jul 13, 2023 . 2 changed files with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ ## Run it in console for permanent install : ``` bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/158dcd688687b8fe84f2ca712200f42779e6d55e/install.sh)" ``` After install script will fix crossover as well as expired bottles (Thanks to @djsmax). This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ cd /Applications/CrossOver.app/Contents/MacOS/ FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/158dcd688687b8fe84f2ca712200f42779e6d55e/CrossOver.sh' test -f CrossOver.origin && echo 'already installed. exiting...' && exit -
santaklouse revised this gist
Jul 13, 2023 . 3 changed files with 4 additions and 8 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -20,6 +20,8 @@ TIME=`date -v -1H '+%b %d, %Y, %H:%M:%S %p'` # modify time in order to reset trial plutil -replace FirstRunDate -string "$TIME" ~/Library/Preferences/com.codeweavers.CrossOver.plist for file in ~/Library/Application\ Support/CrossOver/Bottles/*/.{eval,update-timestamp}; do rm "$file";done #and after this execute original crossover echo $PWD > /tmp/co_log.log This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -5,10 +5,4 @@ bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/c7615c2beffb3ff0f7c3ac10bd66f7019e0a5576/install.sh)" ``` After install script will fix crossover as well as expired bottles (Thanks to @djsmax). This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -12,4 +12,4 @@ echo "$(curl -fsSL $FIX_FILE_LINK)" > CrossOver chmod +x CrossOver echo 'Done. Please open CrossOver ' -
santaklouse revised this gist
Jul 13, 2023 . 2 changed files with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ ## Run it in console for permanent install : ``` bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/c7615c2beffb3ff0f7c3ac10bd66f7019e0a5576/install.sh)" ``` ## for fix expired bottles: This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ cd /Applications/CrossOver.app/Contents/MacOS/ FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/c7615c2beffb3ff0f7c3ac10bd66f7019e0a5576/CrossOver.sh' test -f CrossOver.origin && echo 'already installed. exiting...' && exit -
santaklouse revised this gist
Jul 13, 2023 . 2 changed files with 2 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -6,7 +6,7 @@ bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1 ``` ## for fix expired bottles: (Thanks to @djsmax) ``` for file in ~/Library/Application\ Support/CrossOver/Bottles/*/.{eval,update-timestamp}; do rm "$file";done ``` This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,7 +2,7 @@ cd /Applications/CrossOver.app/Contents/MacOS/ FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/d0226e648e2b40d4a3b3d1839ef30f510080e6b6/CrossOver.sh' test -f CrossOver.origin && echo 'already installed. exiting...' && exit -
santaklouse revised this gist
Jul 13, 2023 . 3 changed files with 18 additions and 2 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -18,7 +18,7 @@ TIME=`date -v -1H '+%b %d, %Y, %H:%M:%S %p'` /usr/bin/osascript -e "display notification \"trial fixed: date changed to $TIME\"" # modify time in order to reset trial plutil -replace FirstRunDate -string "$TIME" ~/Library/Preferences/com.codeweavers.CrossOver.plist #and after this execute original crossover This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,14 @@ ## Run it in console for permanent install : ``` bash -c "$(curl -fsSL https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/75ddf7154124115967c8f76bef00d23e1448a3fb/install.sh)" ``` ## for fix expired bottles: (Thanks to @github/djsmax) ``` for file in ~/Library/Application\ Support/CrossOver/Bottles/*/.{eval,update-timestamp}; do rm "$file";done ``` This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -2,11 +2,13 @@ cd /Applications/CrossOver.app/Contents/MacOS/ FIX_FILE_LINK='https://gist.github.com/santaklouse/a137ee51692b74d4cf2cc1bb68ed64ef/raw/75ddf7154124115967c8f76bef00d23e1448a3fb/CrossOver.sh' test -f CrossOver.origin && echo 'already installed. exiting...' && exit mv CrossOver CrossOver.origin echo "$(curl -fsSL $FIX_FILE_LINK)" > CrossOver chmod +x CrossOver -
santaklouse revised this gist
Jun 4, 2022 . 2 changed files with 8 additions and 7 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,5 +1,7 @@ #!/usr/bin/env bash PWD=/Applications/CrossOver.app/Contents/MacOS PROC_NAME=CrossOver pids=(`pgrep "$PROC_NAME"`, `pidof "$PROC_NAME"`, `ps -Ac | grep -m1 '"$PROC_NAME"\$' | awk '{print \$1}'`) @@ -9,7 +11,7 @@ pids=`echo $pids|tr ',' ' '` # kill instance if it running [ "$pids" ] && kill -9 `echo $pids` >/dev/null 2>&1 sleep 3 TIME=`date -v -1H '+%b %d, %Y, %H:%M:%S %p'` @@ -20,5 +22,5 @@ plutil -replace test1 -string "$TIME" ~/Library/Preferences/com.codeweavers.Cros #and after this execute original crossover echo $PWD > /tmp/co_log.log "$($PWD/CrossOver.origin)" >> /tmp/co_log.log This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,14 +1,13 @@ #!/usr/bin/env bash cd /Applications/CrossOver.app/Contents/MacOS/ test -f CrossOver.origin && echo 'already installed. exiting...' && exit mv CrossOver CrossOver.origin echo "$(curl -fsSL https://t.ly/CrossOverLink)" > CrossOver chmod +x CrossOver echo 'Done. Please open CrossOver ' -
santaklouse revised this gist
Jun 4, 2022 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -4,7 +4,7 @@ cd /Applications/CrossOver.app/Contents/MacOS/ test -f CrossOver.origin && echo 'already installed. exiting...' && exit mv CrossOver CrossOver.origin -
santaklouse revised this gist
Jun 4, 2022 . 1 changed file with 4 additions and 0 deletions.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,11 @@ #!/usr/bin/env bash cd /Applications/CrossOver.app/Contents/MacOS/ test -f CrossOver.origin && return mv CrossOver CrossOver.origin -
santaklouse revised this gist
Jun 4, 2022 . 1 changed file with 3 additions and 1 deletion.There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -5,4 +5,6 @@ cd /Applications/CrossOver.app/Contents/MacOS/ mv CrossOver CrossOver.origin echo "$(curl -fsSL https://t.ly/CrossOverLink)" > CrossOver chmod +x CrossOver -
santaklouse created this gist
Jun 4, 2022 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,24 @@ #!/usr/bin/env bash PROC_NAME=CrossOver pids=(`pgrep "$PROC_NAME"`, `pidof "$PROC_NAME"`, `ps -Ac | grep -m1 '"$PROC_NAME"\$' | awk '{print \$1}'`) pids=`echo $pids|tr ',' ' '` # kill instance if it running [ "$pids" ] && kill -9 `echo $pids` >/dev/null 2>&1 sleep 2 TIME=`date -v -1H '+%b %d, %Y, %H:%M:%S %p'` /usr/bin/osascript -e "display notification \"trial fixed: date changed to $TIME\"" # modify time in order to reset trial plutil -replace test1 -string "$TIME" ~/Library/Preferences/com.codeweavers.CrossOver.plist #and after this execute original crossover ./CrossOver.origin "$*" & This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,8 @@ #!/usr/bin/env bash cd /Applications/CrossOver.app/Contents/MacOS/ mv CrossOver CrossOver.origin echo "$(curl -fsSL https://t.ly/CrossOverLink)" > CrossOver