Eric Guo's blog.cloud-mes.com

Hoping writing JS, Ruby & Rails and Go article, but fallback to DevOps note

A Rails Developer Installation Log on MacBook M4 Pro

Permalink

I got my fouth MacBook Pro today. It's the second Apple Silicon CPU Mac. I bought in PDD and 48G 1T slightly high-end model.

Mac App Store install list

  • AdBlock Pro (11.2.3)
  • Affinity Designer (2.6.2)
  • Affinity Photo (2.6.2)
  • Affinity Publisher (2.6.2)
  • Aware (1.2.0)
  • Diagrams (2.2.0)
  • Elmedia Video Player (8.1)
  • iA Writer (5.6.16)
  • iMovie (10.3.1)
  • Jump Desktop (9.0.99)
  • Keynote (14.4)
  • LiquidText (2.10.36)
  • Logoist 5 (5.1.2)
  • MockFlow (2.7.9)
  • Numbers (14.4)
  • OwlOCR (4.9.2)
  • Pages (14.4)
  • Paper (95)
  • PasteNow (2.22)
  • Pixelmator Pro (3.6.17)
  • SimpleMind Pro (2.6.1)
  • SQLPro Studio (2025.9)
  • Tampermonkey (5.3.6218)
  • Texifier (1.9.31)
  • Things (3.21.6)
  • WeChat (3.8.10)
  • WeCom (4.1.33)
  • Xcode (16.3)

brew install cask list

  • aldente
  • hype
  • chromedriver
  • ghostty
  • imageoptim
  • rapidapi
  • keybase
  • rar
  • zoom
  • cursor
  • rubymine
  • dash
  • google-chrome
  • sublime-merge
  • discord
  • google-cloud-sdk
  • obs
  • sublime-text

brew install console list

  • bash
  • fzf
  • gdu
  • gh
  • git
  • git-filter-repo
  • git-trim
  • go
  • highlight
  • imagemagick
  • jq
  • libpq
  • memcached
  • mysql-client
  • node
  • percona-server
  • poetry
  • postgresql
  • pytorch
  • redis
  • ruby
  • ruff
  • rust
  • smartmontools
  • tmux
  • vips
  • wget
  • yamllint
  • yarn
  • zoxide

bash-it setup

bash-it setup
bash-it enable plugin zoxide proxy base
bash-it enable alias general
bash-it enable completion bash-it brew bundler capistrano cargo aliases export gcloud gem go npm rake ssh system yarn
zoxide init

Some not sign exe file

Open an unsigned macOS executable
xattr -dr com.apple.quarantine /opt/homebrew/bin/rar
# put .rarreg.key to ~
xattr -dr com.apple.quarantine /opt/homebrew/bin/chromedriver

.profile

.profile
export PATH="/opt/homebrew/opt/ruby/bin:/opt/homebrew/lib/ruby/gems/3.4.0/bin:$PATH:/opt/homebrew/opt/postgresql@17/bin:$HOME/.local/bin:$HOME/.cargo/bin"
export HISTSIZE=80000
export ADBLOCK=true
export HOMEBREW_GITHUB_API_TOKEN=
export HOMEBREW_EDITOR="subl"
export HOMEBREW_NO_INSTALL_CLEANUP=1
export HOMEBREW_AUTO_UPDATE_SECS=1800
export LANG=en_US.UTF-8
export LC_CTYPE=en_US.UTF-8
export EDITOR="vim"
export BUNDLER_EDITOR="subl"
export GEM_EDITOR="subl"
export BASH_IT_HTTP_PROXY=http://127.0.0.1:6152/
export BASH_IT_HTTPS_PROXY=http://127.0.0.1:6152/
export NO_PROXY=localhost,127.0.0.1,.local
export GITHUB_APP_ID=
export GITHUB_APP_SECRET=
export NO_ORACLE_ENHANCED=1
export PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true
export MANPATH=/usr/share/man:/opt/homebrew/share/ubuntu_man
export NODE_COMPILE_CACHE=/Users/guochunzhong/.cache/nodejs-compile-cache
export DEVISE_JWT_SECRET_KEY=
export WEFOCUSIN_WECHAT_APPID=
export WEFOCUSIN_WECHAT_SECRET=
export WEFOCUSIN_WECHAT_TOKEN=
export WEFOCUSIN_WECHAT_AES_KEY=
export OPENPROJECT_CORE=/Users/guochunzhong/git/sso/openproject
export DEEPSEEK_ACCESS_TOKEN=sk-
export SWARM_AGENT_DEFAULT_MODEL=deepseek-chat

Please notice ubuntu_man is used by Dash

.bash_profile

.bash_profile
#!/usr/bin/env bash
source /Users/guochunzhong/.profile
alias bde='bundle exec'
alias bdc='bundle check'
alias bdpd='bundle exec cap production deploy'
alias glg="git log --graph --pretty=format:'%Cred%h%Crest -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative"
alias minio-server='minio server /usr/local/var/minio'
alias convert_screen_cast='ffmpeg -i Screencast.mov -vcodec h264 -acodec mp3 Screencast.mp4'
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return ;;
esac
# Path to the bash it configuration
export BASH_IT="/Users/guochunzhong/.bash_it"
# Lock and Load a custom theme file.
# Leave empty to disable theming.
# location "$BASH_IT"/themes/
export BASH_IT_THEME='inretio'
# Some themes can show whether `sudo` has a current token or not.
# Set `$THEME_CHECK_SUDO` to `true` to check every prompt:
#THEME_CHECK_SUDO='true'
# (Advanced): Change this to the name of your remote repo if you
# cloned bash-it with a remote other than origin such as `bash-it`.
# export BASH_IT_REMOTE='bash-it'
# (Advanced): Change this to the name of the main development branch if
# you renamed it or if it was changed for some reason
# export BASH_IT_DEVELOPMENT_BRANCH='master'
# Your place for hosting Git repos. I use this for private repos.
export GIT_HOSTING='git@git.domain.com'
# Don't check mail when opening terminal.
unset MAILCHECK
# Change this to your console based IRC client of choice.
export IRC_CLIENT='irssi'
# Set this to the command you use for todo.txt-cli
export TODO="t"
# Set this to the location of your work or project folders
#BASH_IT_PROJECT_PATHS="${HOME}/Projects:/Volumes/work/src"
# Set this to false to turn off version control status checking within the prompt for all themes
export SCM_CHECK=true
# Set to actual location of gitstatus directory if installed
#export SCM_GIT_GITSTATUS_DIR="$HOME/gitstatus"
# per default gitstatus uses 2 times as many threads as CPU cores, you can change this here if you must
#export GITSTATUS_NUM_THREADS=8
# Set Xterm/screen/Tmux title with only a short hostname.
# Uncomment this (or set SHORT_HOSTNAME to something else),
# Will otherwise fall back on $HOSTNAME.
#export SHORT_HOSTNAME=$(hostname -s)
# Set Xterm/screen/Tmux title with only a short username.
# Uncomment this (or set SHORT_USER to something else),
# Will otherwise fall back on $USER.
#export SHORT_USER=${USER:0:8}
# If your theme use command duration, uncomment this to
# enable display of last command duration.
#export BASH_IT_COMMAND_DURATION=true
# You can choose the minimum time in seconds before
# command duration is displayed.
#export COMMAND_DURATION_MIN_SECONDS=3
# Set Xterm/screen/Tmux title with shortened command and directory.
# Uncomment this to set.
#export SHORT_TERM_LINE=true
# Set vcprompt executable path for scm advance info in prompt (demula theme)
# https://github.com/djl/vcprompt
#export VCPROMPT_EXECUTABLE=~/.vcprompt/bin/vcprompt
# (Advanced): Uncomment this to make Bash-it reload itself automatically
# after enabling or disabling aliases, plugins, and completions.
# export BASH_IT_AUTOMATIC_RELOAD_AFTER_CONFIG_CHANGE=1
# Uncomment this to make Bash-it create alias reload.
# export BASH_IT_RELOAD_LEGACY=1
# Load Bash It
source "$BASH_IT"/bash_it.sh
eval "$(/opt/homebrew/bin/brew shellenv)"
eval "$(zoxide init bash)"
export START_DIR="/Users/guochunzhong/git"
if [[ $PWD == $HOME ]]; then
cd $START_DIR
fi

Install macpm

Install macpm
brew install pipx
pipx install macpm

Install relative go tools used in cursor

Install relative go tools used in cursor
brew install gopls
brew install staticcheck
brew install dlv

The ghostty config

~/.config/ghostty/config
cursor-style-blink = false
font-size = 12
font-thicken = true
font-thicken-strength = 192
font-family = ""
font-family = "Source Code Pro"
font-family = "Sarasa Term SC"
keybind = global:cmd+ctrl+backquote=toggle_quick_terminal
macos-option-as-alt = true
shell-integration-features = cursor,sudo,title,ssh-env,ssh-terminfo
scrollback-limit = 200000000
theme = modus-vivendi
~/.config/ghostty/themes/modus-vivendi
background = #000000
foreground = #ffffff
palette = 0=#000000
palette = 1=#ff8059
palette = 2=#44bc44
palette = 3=#d0bc00
palette = 4=#2fafff
palette = 5=#feacd0
palette = 6=#00d3d0
palette = 7=#bfbfbf
palette = 8=#595959
palette = 9=#ef8b50
palette = 10=#70b900
palette = 11=#c0c530
palette = 12=#79a8ff
palette = 13=#b6a0ff
palette = 14=#6ae4b9
palette = 15=#ffffff

brew, macOS

Comments