代码之家  ›  专栏  ›  技术社区  ›  qknight

带有meld的“git mergetool”无法创建“--output$MERGED”文件

  •  2
  • qknight  · 技术社区  · 9 年前

    我正在使用“gitmergetool”中描述的meld工具 Git merging using Meld 文章

    ~/.gitconfig

    [merge]
            tool = mymeld
            conflictstyle = diff3
    [mergetool "mymeld"]
            keepBackup=false
            cmd = /home/joachim/.nix-profile/bin/meld --diff $BASE $LOCAL --diff $BASE $REMOTE --diff $LOCAL $BASE $REMOTE --output $MERGED
    

    我的问题

    如文章所述,我有3个观点: enter image description here

    但meld从未创建文件$MERGED,因此我想用meld修改的文件看起来像这样:

        systray.cpp
        accountmigrator.cpp
    <<<<<<< HEAD
        quotainfo.cpp
        accountstate.cpp
    ||||||| merged common ancestors
    =======
        addcertificatedialog.cpp
    >>>>>>> adds 'SSL client certificate' support from n.octeau with qknight changes as:
        wizard/abstractcredswizardpage.cpp
        wizard/owncloudadvancedsetuppage.cpp
    

    熔化错误消息

    “git mergetool”也会打印此错误:

    Normal merge conflict for 'src/libsync/account.cpp':
      {local}: modified file
      {remote}: modified file
    
    ** (process:30916): WARNING **: Trying to register gtype 'GMountMountFlags' as enum when in fact it is of type 'GFlags'
    
    ** (process:30916): WARNING **: Trying to register gtype 'GDriveStartFlags' as enum when in fact it is of type 'GFlags'
    
    ** (process:30916): WARNING **: Trying to register gtype 'GSocketMsgFlags' as enum when in fact it is of type 'GFlags'
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryCombo::history-id after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryEntry::history-id after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryFileEntry::directory-entry after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryFileEntry::filename after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryFileEntry::default-path after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryFileEntry::modal after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryFileEntry::dialog-title after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property HistoryFileEntry::history-id after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: attempting to add an interface (GtkEditable) to class (HistoryFileEntry) after class_init
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property meld+ui+emblemcellrenderer+EmblemCellRenderer::icon-tint after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property meld+ui+emblemcellrenderer+EmblemCellRenderer::icon-name after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    /nix/store/wsxxxn51aajzmx0zcq0dxfajky4rid7k-pygobject-2.28.6/lib/python2.7/site-packages/gobject/__init__.py:115: Warning: Attempt to add property meld+ui+emblemcellrenderer+EmblemCellRenderer::emblem-name after class was initialised
      type_register(cls, namespace.get('__gtype_name__'))
    Fontconfig error: "/nix/store/y6sibqy2c9skmivxs4sz4p4zrjgpflbv-fontconfig-ultimate-20141123/etc/fonts/conf.d/10-scale-bitmap-fonts.conf", line 70: non-double matrix element
    Fontconfig error: "/nix/store/y6sibqy2c9skmivxs4sz4p4zrjgpflbv-fontconfig-ultimate-20141123/etc/fonts/conf.d/10-scale-bitmap-fonts.conf", line 70: non-double matrix element
    Fontconfig warning: "/nix/store/y6sibqy2c9skmivxs4sz4p4zrjgpflbv-fontconfig-ultimate-20141123/etc/fonts/conf.d/10-scale-bitmap-fonts.conf", line 78: saw unknown, expected number
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f86966ac910 (HistoryFileEntry at 0x18615b0)>: unknown signal name: changed
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f86966ac7d0 (HistoryFileEntry at 0x1861400)>: unknown signal name: changed
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f869630cc30 (HistoryFileEntry at 0x192da90)>: unknown signal name: changed
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f869630ca50 (HistoryFileEntry at 0x192d8e0)>: unknown signal name: changed
    /nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/filediff.py:1084: Warning: g_object_set_qdata: assertion 'G_IS_OBJECT (object)' failed
      self.textview[len(files) >= 2].grab_focus()
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f869447a230 (HistoryFileEntry at 0x19495d0)>: unknown signal name: changed
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f8694472f50 (HistoryFileEntry at 0x1949420)>: unknown signal name: changed
    Traceback (most recent call last):
      File "/nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/ui/historyentry.py", line 365, in <lambda>
        entry.connect("changed", lambda *args: self.emit("changed"))
    TypeError: <HistoryFileEntry object at 0x7f8694472e10 (HistoryFileEntry at 0x1949270)>: unknown signal name: changed
    /nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/meldwindow.py:463: Warning: g_object_set_qdata: assertion 'G_IS_OBJECT (object)' failed
      self.notebook.set_current_page(self.notebook.page_num(page.widget))
    /nix/store/1yw4haf25x43pxnlgcbhx6v6ra9gfnk6-meld-1.8.6/lib/meld/meld/meldwindow.py:641: Warning: g_object_set_qdata: assertion 'G_IS_OBJECT (object)' failed
      self.notebook.remove_page(page_num)
    src/libsync/account.cpp seems unchanged.
    Was the merge successful? [y/n] 
    

    问题

    丢失的$MERGED文件可能是由meld问题引起的。然而,我认为这个问题是 NixOS特定。

    meld问题也在 http://forums.gentoo.org/viewtopic-t-973234-view-previous.html?sid=1b42d7d0d9e268b592dc476c8c38bc89 但我不明白这是否是我问题的原因。

    请给我一些提示,我下一步可以做什么。

    1 回复  |  直到 7 年前
        1
  •  2
  •   qknight    9 年前

    固定的!问题确实是meld-1.8.6根本没有将文件保存到--output,而是meld-3.12.3正在保存文件。因此,这个问题现在通过使用新版本解决了(在nixpkgs中还没有!)