---
title: "分支、標籤與遠端儲存庫"
description: "在 gitā 中檢出、建立、重新命名與刪除分支，設定上游分支、建立標籤、管理遠端儲存庫，並在擷取、拉取與推送前透過視窗預覽即將發生的變化。"
url: https://getgita.app/zh-hant/features/branches
lang: zh-Hant
---

# 分支、標籤 與遠端儲存庫

側邊欄列出了你的所有分支、遠端儲存庫、標籤與 Stash。在任意一項上右鍵按一下，所有可用操作都在其中。

A live copy of the app is on the page: https://getgita.app/zh-hant/features/branches

## 試試看

1. 右鍵按一下側邊欄中的某個分支。
2. 按一下工具列中的 **分支** 按鈕建立一個新分支。
3. 按一下工具列中的儲存庫名稱切換分支。
4. 依序按一下 **擷取** 與 **推送**。

## 分支與遠端

- **每個分支一個選單.** 檢出、合併到目前分支、變基到其上、推送、重新命名、設定上游分支、刪除、在瀏覽器中開啟或複製名稱。歷史紀錄中的分支標籤上也有完全相同的選單。
- **資料夾中的分支.** 名稱中帶有斜線的分支（如 feature/checkout）會在側邊欄自動歸類為資料夾。
- **標籤.** 可以在任意提交上建立輕量標籤或附帶說明的附註標籤。
- **遠端儲存庫.** 「管理遠端儲存庫」會列出每個遠端儲存庫及其網址。支援新增、修改網址、重新命名、移除或從中擷取。GitHub、GitLab 與 Bitbucket 儲存庫會顯示各自的圖示。
- **擷取、拉取與推送.** 每項操作都會先開啟確認視窗。擷取支援同步所有遠端儲存庫；拉取可選僅快進、合併或變基，並可自動暫存再恢復變更；推送支援附帶標籤並為新分支設定上游。
- **謹慎的強制推送.** 如果遠端儲存庫存在你尚未擷取的提交，強制推送會自動停止，防止誤覆蓋他人的工作。
- **安全刪除.** 「刪除本機分支」只會刪除已經完成合併的分支。

## Questions, answered

### Is force push safe in gitā?

Force Push stops if the remote has commits you have not fetched, so you do not overwrite someone else's work by accident.

### Can I manage remotes in gitā?

Yes. Manage Remotes lists each remote with its address. Add one, change its address, rename it, remove it or fetch from it.

[全部功能](https://getgita.app/zh-hant/features.md)

- **下載 macOS 版:** https://github.com/rolottr/gita/releases/latest
- **在 GitHub 上查看:** https://github.com/rolottr/gita

---

Apple, macOS and Mac are trademarks of Apple Inc. Git is a trademark of Software Freedom Conservancy. GitHub is a trademark of GitHub, Inc. Vercel is a trademark of Vercel Inc. Claude is a trademark of Anthropic, PBC. gitā is independent software and is not affiliated with any of them. 問題回報: https://github.com/rolottr/gita/issues
