删除不反映原点的远程分支

Deleting a remote branch not reflecting on the origin

我正在使用我的两台笔记本电脑和我的个人 GitHub 帐户来模拟两个开发人员使用 git 在一个团队中工作。我的仓库只有一个 master 和一个 feature 分支,以及一个简单的文本文件。

在一台笔记本电脑(一个开发者的帐户)上,我使用命令行 bash 发出 git 命令。我将功能与 master 合并,然后在本地删除它:$ git branch -d feature

当然,单独推送不会删除远程功能分支,所以我这样做:$ git push origin --delete feature

然后,我希望看到这个远程删除显示在另一台笔记本电脑上(其他开发人员使用 SourceTree 来做 git 东西)但是原始功能在 SourceTree 上仍然存在,尽管有一些刷新...

我环顾四周,想也许还有其他命令。我遇到了以下两个:

$ git push origin :feature

$ git push -u origin feature

但是,对于上述每个 git bash 命令(第一个开发人员),我都得到以下两个错误:

error: unable to delete 'feature': remote ref does not exist
error: failed to push some refs to 'https://github.com/MyRepo/Repo.git'

error: src refspec feature does not match any.
error: failed to push some refs to 'https://github.com/MyRepo/Repo.git'

这两条错误信息说明远程特性分支确实被删除了。 ?

我错过了什么?为什么第一个人做的远程分支删除在远程没有生效?

在本地清理远程删除的分支(和其他):

$ git remote prune origin

查看远程分支列表:

$ git branch -r