一年一度的iOS 系统 API适配来了,9 月 14 日起 App Store Connect 已经开放 iOS 15 和 iPadOS 15 App 的提交,同时苹果宣布自 2022 年 4 月起,所有提交至 App Store 的 iOS 和 iPadOS app 都必须使用 Xcode 13 和 iOS 15 SDK 构建。
Xcode 13 正式版包含 iOS 15,iPadOS 15,tvOS 15,watchOS 8 以及 macOS Big Sur 11.3 SDK。
Xcode 13 需在 macOS 11.3 及以上版本运行
,支持 iOS 9,tvOS 9,watchOS 2 及以上系统设备调试; 也正式支持了 Vim。 Xcode 13 Release Notes: https://developer.apple.com/documentation/xcode-release-notes/xcode-13-release-notes
正是基于近期iOS15出来了,需要升级IDE进行适配。发现磁盘空间不足,连操作系统都无法升级了。
目前使用的Mac磁盘空间是121GB,至少需要换256G的。
可见平时的Mac清理的重要性,于是乎分享下更换Mac时的备份和清理小知识。
经常备份重要的配置和文件是良好的习惯,尤其当你Mac的配置跟不上开发要求的时候显得尤其重要。
https://www.alfredapp.com/help/
https://www.charlesproxy.com 4.2
https://download.csdn.net/download/u011018979/12852517
#多开WeChat
alias wx='nohup /Applications/WeChat.app/Contents/MacOS/WeChat > /dev/null &'
推荐登录Google账号选择同步数据(扩展、书签)
安装Xcode的时候,由于公司的Mac经常提示”可用的磁盘空间不足,无法安装此产品。“,因此记录一下。
在这里插入图片描述
如果从AppStore升级Xcode失败的话,可通过URL下载Xcode
Xcode12:https://download.developer.apple.com/Developer_Tools/Xcode_12/Xcode_12.xip 同理:11 直接修改URL参数即可
https://download.developer.apple.com/Developer_Tools/Xcode_11/Xcode_11.xip
https://download.developer.apple.com/Developer_Tools/Xcode_10/Xcode_10.xip
#!/bin/sh
# The ~/Library/Developer/Xcode/iOS DeviceSupport folder is basically only needed to symbolicate crash logs.
# You could completely purge the entire folder. Of course the next time you connect one of your devices, Xcode would redownload the symbol data from the device.
# I clean out that folder once a year or so by deleting folders for versions of iOS I no longer support or expect to ever have to symbolicate a crash log for.
killall -9 Xcode
killall -9 com.apple.CoreSimulator.CoreSimulatorService
rm -rf ~/Library/Developer/Xcode/iOS\ DeviceSupport/*
rm -rf ~/Library/Developer/Xcode/DerivedData/*
rm -rf ~/Library/Developer/Xcode/Archives/*
rm -rf ~/Library/Developer/Xcode/Products/*
rm -rf ~/Library/Developer/CoreSimulator/Devices/*
killall -9 com.apple.CoreSimulator.CoreSimulatorService
killall -9 Xcode
rm -rf ~/.Trash/
exit 0%
open ~/Library/Caches
在这里插入图片描述
在这里插入图片描述
以我的Mac为例子,Mac系统能清理的只有文稿和应用程序,系统和其他占据了87G是无法清理的。
/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"
brew install zsh
安装方式2: git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh
cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc
# <!-- 修改主题 -->
open ~/.zshrc
# 修改 `ZSH_THEME=”robbyrussell”`,主题在 ~/.oh-my-zsh/themes 目录下。
在~/.zshrc 引用bash的配置source ~/.bash_profile
配置bash的时候,采用~/.bash_profile;配置zsh的时候,采用open ~/.zshrc
autojump是一个命令行工具,它可以使用快捷命令,直接跳转到配置好的目录,而不用管现在身在何处,依赖zsh。
j -a 你定义的快捷命令 ‘需要跳转的目录位置’
使用vim ~/.zshrc
a. 找到 plugins=,在后面添加autojump:plugins=(git autojump) b. 新开一行,添加:[[ -s (brew --prefix)/etc/profile.d/autojump.sh ]] && .
(brew --prefix)/etc/profile.d/autojump.sh c. :wq保存退出,重启终端。
plugins=(
git autojump
)
[[ -s $(brew --prefix)/etc/profile.d/autojump.sh ]] && . $(brew --prefix)/etc/profile.d/autojump.sh
sudo gem install cocoapods
显示/隐藏 文件
alias fs='defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder'
alias fh='defaults write com.apple.finder AppleShowAllFiles -boolean false ; killall Finder'
设置git名称及对应的邮箱:git config --global --edit
connecting-to-github-with-ssh 免密码进行SSH连接
【Mac 使用~/.ssh 的config 配置GitHub SSH keys】同样适用于gitlab 原文链接:https://blog.csdn.net/z929118967/article/details/78234772 ———————————————— 版权声明:本文为CSDN博主「iOS逆向」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
清理Mac文件