我有一个分支,我想与主人合并。我使用了以下命令:
git checkout master
git merge lwIP
我得到了以下答案,我认为这是正确的:
fer@fer-Inspiron-5558:~/workspaceSDK/ControlMetro$ git merge lwIP
Updating 2f1a663..0ce296e
Fast-forward
.../sensores/sensores_botones.c | 6 +-
src/app/control_metro/main.c | 15 +-
.../{funciones_com_VGA.c => funciones_com_lwIP.c} | 94 +++++-
.../funciones_comunicacion.h | 1 +
.../tarea_comunicacion.c | 8 +-
src/hw_services/display_vga/display_vga.c | 2 +-
src/hw_services/hal_core/gpio_services.c | 171 +++++++++++
src/hw_services/hal_core/gpio_services.h | 29 ++
src/hw_services/hal_core/hw_abstraction.c | 314 ---------------------
src/hw_services/hal_core/hw_abstraction.h | 52 ----
src/hw_services/hal_core/timer_services.c | 281 ++++++++++++++++++
src/hw_services/hal_core/timer_services.h | 74 +++++
src/hw_services/lwIP/lwIP_server.c | 164 +++++++++++
src/hw_services/lwIP/lwIP_server.h | 17 ++
14 files changed, 844 insertions(+), 384 deletions(-)
rename src/app/control_metro/tarea2_comunicacion_exterior/{funciones_com_VGA.c => funciones_com_lwIP.c} (56%)
create mode 100644 src/hw_services/hal_core/gpio_services.c
create mode 100644 src/hw_services/hal_core/gpio_services.h
delete mode 100644 src/hw_services/hal_core/hw_abstraction.c
delete mode 100644 src/hw_services/hal_core/hw_abstraction.h
create mode 100644 src/hw_services/hal_core/timer_services.c
create mode 100644 src/hw_services/hal_core/timer_services.h
create mode 100644 src/hw_services/lwIP/lwIP_server.c
create mode 100644 src/hw_services/lwIP/lwIP_server.h
然后我尝试删除lwIP分支,它会给我下一个错误:
fer@fer-Inspiron-5558:~/workspaceSDK/ControlMetro$ git branch -d lwIP
warning: not deleting branch 'lwIP' that is not yet merged to
'refs/remotes/origin/lwIP', even though it is merged to HEAD.
error: The branch 'lwIP' is not fully merged.
If you are sure you want to delete it, run 'git branch -D lwIP'.
然后推动它是不可能的...我在Git上真的很新,我在Git页面上关注了这个教程,但我不知道如何解决这个问题。
谢谢!
答案 0 :(得分:1)
不删除尚未合并的分支'lwIP' 'refs / remotes / origin / lwIP',即使它被合并到HEAD。
输出为您提供答案。 lwIP
分支已合并到您的本地主服务器,但未合并到lwIP
远程服务器上的origin
分支。如果您无法推送master
,则可能需要先pull
合并上游更改。
您可以根据建议使用-D
选项强制进行本地删除,也可以结帐lwIP
并推送到origin
遥控器。如果您有上游更改,则可能需要将origin/lwIP
拉入本地lwIP
。