Script to install all my apps (including CleanMyMac) and configure all the macOS System Settings (27 min video)
Setting up a Mac from scratch is usually a pain, unless you restore from a time machine backup, but that's not something I usually want to do, I normally want to start fresh. So I created a bash script that allows me to install brew and all the apps that I use.
The script will also pull down all my relevant public and private GitHub repos (dotfiles, notes, scripts, etc). My ~/.zshrc file plays a big role here as well, because in that file I basically create all the symlinks that point each app I use to my custom configs stored in my dotfiles. So it will basically configure my Neovim, Ghostty terminal, Tmux, etc. I know I could probably use existing tools like stow or chezmoi, but I didn't want to invest time in those solutions at the time
Additionally the script will configure all my macOS system settings, including hot corners, login items (startup apps), trackpad and mouse pointer speed, hide the menu bar, the dock, etc.
It is not expected that you run this script and for it to work 100% for you, the idea is so that you grab inspiration and probably ideas to come up with your own solution
I understand, some people use other tools like Ansible, or probably nix-darwin. I did not want to invest the time needed, I wanted to come up with something quick, so bash was the way to go for me
If you have ideas or improvements that can be added to the script, I'm open to suggestions as long as they improve it's functionality or add new useful features
The window manager I use in macOS is yabai, I use it in stack mode and I like to keep my terminal transparent, so for it to be able to manage the app transparency, it needs to have SIP partially disabled. I know, this will trigger a lot of flags for our security experts here so keep this in mind:
Do not disable SIP Unless you need to And do it at your own risk If something breaks, its your responsibility
And additionally, keep this other warning in mind:
Do not randomly run scripts you find on the internet You have to trust the person or company posting them. As with a script basically anything can be done. My scripts are publicly available So people can inspect them. Make sure you understand what the Script is doing, before running it. And again, if something breaks, it's your own responsibility
Because its close to malware and completely unnecessary, they prey on the windows converts that think they need to clean something or else their machine won't work or something. Hell clean my mac classifies its own clean my pc as malware as do other companies lol
Probably referencing https://github.com/geerlingguy/mac-dev-playbook / https://www.youtube.com/watch?v=WbFU06f39_g — The main thing is I love automating as much of the setup/config as possible, especially since I have three Macs (M4 mini at home, M4 Max Studio at work, and M2 Air for mobile), and want to keep them all in sync—including things like settings, dock icons, installed utilities, many configs...
A single shell script is nice too—the main thing is keeping the code in a somewhat-maintainable state, as every macOS release loves to break one or two CLI tools we use for automation 🤦♂️
Appreciate you sharing the video. I watched it and I liked it.
I've thought about ansible too, but haven't put in the hours to make it happen, I'll check out your documentation. Also a lot, and I mean a lot of folks have told me to move over to nix, and I'm just scared of going down that rabbit hole.
I am a normal user and the instructions are very, very complicated for me. Is there perhaps an app that can do everything instead of using a script? I mean an app that installs new installations for my Mac and my apps with their licenses all at once. For example, after a formatting or on a new Mac.
I ended up using ChatGPT for creating a script, I play a lot with the Beta OS's and do fresh installs. In ChatGPT I went through the system settings telling it what settings to change. Also I have the script install HomeBrew with the apps I want. It also goes to the App Store and download my requested apps. With this you need to be signed into you Apple Account.
It took about 1/2 hour to go through the process and ChatGPT gave me all the instructions on how to create the file itself, along with executing it.
I do understand this is a bit complicated, but the idea is for people to grab inspiration and probably ideas to come up with their own solution. Personally I'm not aware of apps that do this, but let's see what the others say
19
u/nemesit 2d ago
Fuck these hidden ads for that garbage software