# 用 Homebrew 安裝 Google Cloud SDK(適用 macOS) brew install google-cloud-sdk # 初始化 gcloud,進行登入與基本設定 gcloud init # 設定當前使用的 GCP 專案(記得換成你的專案 ID) gcloud config set project [YOUR_PROJECT_ID] # 查看目前帳戶底下有哪些 GCP 專案 gcloud projects list # 查詢目前帳戶下的所有 Compute Engine 虛擬機(VM) gcloud compute instances list