есть ли способ эмулировать git show в mercurial?

есть ли способ эмулировать git show в mercurial?

Я часто использую $ git show commitid, чтобы посмотреть, какие изменения сделал человек. Например -

┌─[shirish@debian] - [~/games/libcpuid] - [10029]
└─[$] git show b5bd535

commit b5bd5355829dcd123fba20a3c1d14f2bc139dc43
Author: eloaders <[email protected]>
Date:   Mon Oct 3 20:10:02 2016 +0200

Fix #72

let libcpuid 0.4.0 and brethen conflict with libcpuid 0.3.0 and its
brethen

diff --git a/debian/control b/debian/control
index ba71f44..b70c5da 100644
--- a/debian/control
+++ b/debian/control
@@ -9,7 +9,7 @@ Homepage: https://github.com/anrieff/libcpuid
 Package: libcpuid14
 Architecture: amd64 i386
 Depends: ${shlibs:Depends}, ${misc:Depends}, ${misc:Pre-Depends}
-Replaces: libcpuid11

+Replaces: libcpuid11, libcpuid13
 Description: small C library for x86/x86_64 CPU detection and feature extraction

Это изhttps://github.com/anrieff/libcpuidно это не вопрос. Есть ли похожий способ использовать mercurial с цветными diff и всем остальным? Я пробовал $hg show changeset id, но ничего не вышло :(

решение1

Включить расширение цвета

Используйте что-то вроде hg log -r NNN -v -p -g(нельзя показать цветные фрагменты, но ониявляютсяздесь)

changeset:   7:32bbc6bc3867
user:        AL <lazybadger@*>
date:        Tue Nov 20 03:51:53 2012 +0600
files:       404.php
description:
Localization of page


diff --git a/404.php b/404.php
--- a/404.php
+++ b/404.php
@@ -1,8 +1,8 @@
 <?php get_header(); ?>

   <article class="noposts">
-       <h2>404 - Content Not Found</h2>
-       <p>We don't seem to be able to find the content you have requested - why not try a search below?</p>
+       <h2><?php _e('404 - Content Not Found','fiver' ); ?></h2>
+       <p><?php _e('We don&rsquo;t seem to be able to find the content you have requested - why not try a search below?','fiver' ); ?></p>
        <?php get_search_form(); ?>
   </article>

Если вы хотите изменить вывод по умолчанию - просто напишите свой стиль и добавьте -T stylenameв параметры журнала

Примечание

Используемые параметры:

  • -rопределить область отображения наборов изменений (это может быть отдельный набор изменений или набор изменений)
  • -v(опционально) подробный вывод: немного изменить формат вывода по умолчанию и добавить строку с файлами, затронутыми в каждом наборе изменений (не имеет аналогов в default git show)
  • -pдобавить разницу изменений в вывод журнала
  • -gвывести указанный выше diff в «расширенном формате Git» (потому что in git showdiff всегда в формате Git)

Связанный контент