首先要安装旧版 OneDrive, 然后禁止其自动更新.
参考链接:
- https://answers.microsoft.com/zh-hans/msoffice/forum/all/mac-onedrive/d34a4954-7bd5-41c4-911c-92fc8c2e7a54
- https://answers.microsoft.com/en-us/msoffice/forum/all/download-earlier-version-of-onedrive-on-mac/e2fd3176-34eb-47bf-9643-e6cbf342bfa9
首先, 找到对应系统能够支持的最高版本.
在以下网站中找到可用版本号: OneDrive 发行说明
然后, 将下面的版本号替换为适合系统版本的版本号, 并下载 pkg.
https://oneclient.sfx.ms/Mac/Installers/23.054.0313.0003/universal/OneDrive.pkg
在安装成功后, 不要运行 OneDrive. 在终端中运行以下命令:
结束更新过程:
launchctl remove com.microsoft.OneDriveStandaloneUpdater
sudo launchctl remove com.microsoft.OneDriveStandaloneUpdaterDaemon
sudo launchctl remove com.microsoft.OneDriveUpdaterDaemon
删除配置文件:
sudo rm /Library/LaunchAgents/com.microsoft.OneDriveStandaloneUpdater.plist
sudo rm /Library/LaunchDaemons/com.microsoft.OneDriveStandaloneUpdaterDaemon.plist
sudo rm /Library/LaunchDaemons/com.microsoft.OneDriveUpdaterDaemon.plist
去除更新程序可执行权限:
sudo chmod -x '/Applications/OneDrive.app/Contents/OneDrive Updater.app/Contents/MacOS/OneDriveUpdater'
sudo chmod -x /Applications/OneDrive.app/Contents/StandaloneUpdater.app/Contents/MacOS/OneDriveStandaloneUpdater