mac无限刷新navicat试用时间

1.必看

原理就是删除一些文件,记录时间重置。建议买正版,禁止商用。

2.代码

Lua 复制代码
#!/bin/bash

set -e

file=$(defaults read /Applications/Navicat\ Premium.app/Contents/Info.plist)

regex="CFBundleShortVersionString = \"([^\.]+)"
[[ $file =~ $regex ]]

version=${BASH_REMATCH[1]}

echo "Detected Navicat Premium version $version"

case $version in
    "17")
        file=~/Library/Preferences/com.navicat.NavicatPremium.plist
        ;;
    "16")
        file=~/Library/Preferences/com.navicat.NavicatPremium.plist
        ;;
    "15")
        file=~/Library/Preferences/com.prect.NavicatPremium15.plist
        ;;
    *)
        echo "Version '$version' not handled"
        exit 1
        ;;
esac

echo -n "Reseting trial time..."

regex="([0-9A-Z]{32}) = "
[[ $(defaults read $file) =~ $regex ]]

hash=${BASH_REMATCH[1]}

if [ ! -z $hash ]; then
    defaults delete $file $hash
fi

regex="\.([0-9A-Z]{32})"
[[ $(ls -a ~/Library/Application\ Support/PremiumSoft\ CyberTech/Navicat\ CC/Navicat\ Premium/ | grep '^\.') =~ $regex ]]

hash2=${BASH_REMATCH[1]}

if [ ! -z $hash2 ]; then
    rm ~/Library/Application\ Support/PremiumSoft\ CyberTech/Navicat\ CC/Navicat\ Premium/.$hash2
fi

echo " Done"

3.使用

新增一个文件,名字随便起,把上面脚本贴进去,授权,执行就可以刷新了。

我文件名字:jihuo.sh

授权:chmod 777 jihuo.sh

执行:sh jihuo.sh 或者 ./jihuo.sh

相关推荐
共享家95275 小时前
linux-数据链路层
linux·网络·macos
CZIDC15 小时前
MacOS字体看起来比在 Windows 上更好?
macos
Cosmoshhhyyy1 天前
linux远程部署dify和mac本地部署dify
linux·运维·macos
行星0081 天前
mac 通过homebrew 安装和使用nvm
macos·npm·node.js
2501_928094651 天前
Mac电脑录屏工具 Omi录屏专家(Mac中文)
macos·mac·录屏工具·omi
森之鸟1 天前
Mac chrome浏览器下载DevEco Studio 6.0.0 Beta2失败
前端·chrome·macos
FairGuard手游加固2 天前
版本更新!FairGuard-Mac加固工具已上线!
macos
金玉满堂@bj2 天前
OS设备UDID查看方法
macos·objective-c·cocoa
庸懒2 天前
Electron自定义菜单栏及Mac最大化无效的问题解决
前端·macos·electron