banner
codeacg

codeacg

额. 每天的事情 看番 + 写代码(学
github
telegram

Recording what the newly unboxed Mac mini did automatically

1686063209.jpg

1. Unboxing and Activation#

2. Network#

surge for mac installation

3. Password Tool#

1password installation, after all, I don't know any of my passwords...

4. Homebrew Installation#

  1. Install homebrew with one command:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

After the installation is complete, execute a command to add homebrew to the macOS environment variable.

echo 'eval "$(/opt/homebrew/bin/brew shellenv)"' >> ~/.zprofile

Use the source command to take effect immediately, or you can restart the terminal.

source ~/. zprofile
  1. Install download sources (tap)
brew tap homebrew/cask-fonts
brew tap homebrew/core
brew tap homebrew/cask
brew tap homebrew/services

homebrew/core: Homebrew's official repository, which contains many commonly used software packages.
homebrew/cask: Homebrew's official Cask repository, which contains many macOS applications.
homebrew/bundle: Homebrew's official Bundle repository, which contains Bundle-related commands and tools.
homebrew/services: Homebrew's official service plugin repository, which contains some common service plugins such as MySQL, Redis, etc.
homebrew/cask-fonts: Homebrew's font repository, which contains many font packages.
Here is the official GitHub of homebrew, feel free to take what you need!

  1. Install software
brew install aria2 docker ffmpeg git go highlight mackup mkvtoolnix node nvm python rclone curl pbcopy redis wget yt-dlp 1password aegisub alt-tab appflowy arc avifquicklook background-music balenaetcher beyond-compare devtoys devutils discord downie drawio espanso firefox gltfquicklook google-chrome iina input-source-pro ipynb-quicklook istat-menus jpc-qlcolorcode jq keka microsoft-edge mos mouse-fix notion nutstore obs obsidian onedrive onekey one-switch orion osirix-quicklook picgo popclip postman qbittorrent qlimagesize qlstephen qlvideo qq quicklook-csv quicklook-json quicklook-pat quicklookase raycast slack sourcetree spotify sublime-text surge telegram thunder tinypng4mac todesk typora visual-studio-code vim warp wechat wpsoffice-cn yesplaymusic

5. Enable "Any Source"#

Solve the problem of "damaged and cannot be opened. You should move it to the trash" when installing software on Mac
Open [Launchpad], select [Terminal], and enter:

sudo spctl  --master-disable

Then press Enter, continue to enter the password (the password is not visible when entered), and then press Enter.
Then open [System Preferences], select [Security & Privacy], select [General], and you can see that [Any Source] has been selected.
Then open the file for installation.

6. Set Finder#

SettingOperation
Show all filename extensions1685973693.png
Set unified style for Finder1685976182.png
(Note that modified Finder styles do not take effect globally)

7. Rename alias#

Create a file

touch ~/.bashrc

Open the file and write the following command in the file

open ~/.bashrc
  1. Set ll
alias ll=ls -l
  1. Set python
alias python=python3

8. Adjust the hiding speed of the Dock bar#

defaults write com.apple.Dock autohide-delay -float 0 && killall Dock

Regret medicine

defaults delete com.apple.Dock autohide-delay && killall Dock

Little knowledge:

The difference between .bashrc, .zshrc, .profile, and .bash_profile
1️⃣ Difference between bashrc and profile
bashrc is automatically executed after the system starts.
After setting, you can update bashrc with the terminal command source bashrc
profile is only executed after the user logs in.
After setting, you can update the profile with the terminal command source profile
PS: Usually we modify bashrc, and some Linux distributions may not have the profile file
The variables set in /etc/profile (global) can apply to any user, while the variables set in ~/.bashrc and others (local) can only inherit the variables in /etc/profile, and they are "parent-child" relationship.
2️⃣ .bash_profile
~/.bash_profile: Each user can use this file to enter shell information dedicated to their own use. When the user logs in, this file is executed only once! By default, it sets some environment variables and executes the user's .bashrc file.
~/.bash_profile: It is run when entering bash interactively and in login mode.
~/.bashrc: It is run when entering bash interactively and in non-login mode. Usually, the two settings are roughly the same, so the former will usually call the latter.
3️⃣ .zshrc
Global variable settings for the zsh terminal command tool, different from bashrc, the default configuration is in bashrc for many Linux systems
If you use zsh, configure it in zshrc

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.