Patchwork [4,of,4] annotate: remove dead code to not convert path to relative path

login
register
mail settings
Submitter Yuya Nishihara
Date Nov. 24, 2018, 12:34 p.m.
Message ID <1aac31914fee54803cd5.1543062858@mimosa>
Download mbox | patch
Permalink /patch/36765/
State Accepted
Headers show

Comments

Yuya Nishihara - Nov. 24, 2018, 12:34 p.m.
# HG changeset patch
# User Yuya Nishihara <yuya@tcha.org>
# Date 1543057555 -32400
#      Sat Nov 24 20:05:55 2018 +0900
# Node ID 1aac31914fee54803cd5c206f0dddcc18f6120e2
# Parent  3ba66c3809b43da8216aea05b0cef15bf3a53109
annotate: remove dead code to not convert path to relative path

It's annotate. There should be at least one file path specified.
via Mercurial-devel - Nov. 26, 2018, 8:42 a.m.
On Sat, Nov 24, 2018 at 4:40 AM Yuya Nishihara <yuya@tcha.org> wrote:

> # HG changeset patch
> # User Yuya Nishihara <yuya@tcha.org>
> # Date 1543057555 -32400
> #      Sat Nov 24 20:05:55 2018 +0900
> # Node ID 1aac31914fee54803cd5c206f0dddcc18f6120e2
> # Parent  3ba66c3809b43da8216aea05b0cef15bf3a53109
> annotate: remove dead code to not convert path to relative path
>

Queued, thanks.

Patch

diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -412,8 +412,7 @@  def annotate(ui, repo, *pats, **opts):
         rootfm.startitem()
         rootfm.data(path=abs)
         if not opts.get('text') and fctx.isbinary():
-            rootfm.plain(_("%s: binary file\n")
-                         % ((pats and m.rel(abs)) or abs))
+            rootfm.plain(_("%s: binary file\n") % m.rel(abs))
             continue
 
         fm = rootfm.nested('lines', tmpl='{rev}: {line}')