Patchwork [2,of,2] doc: make it easier to read how to enable extensions

login
register
mail settings
Submitter Jordi Gutiérrez Hermoso
Date June 6, 2013, 6:06 p.m.
Message ID <da16d21cf4ed9f0c48ef.1370541961@Iris>
Download mbox | patch
Permalink /patch/1709/
State Accepted
Commit da16d21cf4ed9f0c48efcf26f732657c1fca884b
Headers show

Comments

Jordi Gutiérrez Hermoso - June 6, 2013, 6:06 p.m.
# HG changeset patch
# User Jordi Gutiérrez Hermoso <jordigh@octave.org>
# Date 1370541903 14400
# Branch stable
# Node ID da16d21cf4ed9f0c48efcf26f732657c1fca884b
# Parent  73066ba46ec5631470617e22bd5ed0e036890c73
doc: make it easier to read how to enable extensions

We tell people all the time that enabling extensions is not a scary
thing to do, but we don't make it easy enough for an absolute novice
to do so. When they see a suggestion to do "hg extfoo bar", the error
message tells them "see hg help extensions", but that help page
doesn't actually tell them where configuration files are.

Furthermore, the big warning about why extensions aren't enabled by
default should be pushed down a little bit. Most of the extensions
shipped by hg are not all that scary, and some very basic and useful
cosmetic extensions like graphlog, color, pager, and progress, should
be enabled for many hg users.
Matt Mackall - June 6, 2013, 10:45 p.m.
On Thu, 2013-06-06 at 14:06 -0400, Jordi Gutiérrez Hermoso wrote:
> # HG changeset patch
> # User Jordi Gutiérrez Hermoso <jordigh@octave.org>
> # Date 1370541903 14400
> # Branch stable
> # Node ID da16d21cf4ed9f0c48efcf26f732657c1fca884b
> # Parent  73066ba46ec5631470617e22bd5ed0e036890c73
> doc: make it easier to read how to enable extensions

These are queued for stable, thanks.

Patch

diff --git a/mercurial/help/extensions.txt b/mercurial/help/extensions.txt
--- a/mercurial/help/extensions.txt
+++ b/mercurial/help/extensions.txt
@@ -3,14 +3,6 @@ 
 existing commands, change the default behavior of commands, or
 implement hooks.
 
-Extensions are not loaded by default for a variety of reasons:
-they can increase startup overhead; they may be meant for advanced
-usage only; they may provide potentially dangerous abilities (such
-as letting you destroy or modify history); they might not be ready
-for prime time; or they may alter some usual behaviors of stock
-Mercurial. It is thus up to the user to activate extensions as
-needed.
-
 To enable the "foo" extension, either shipped with Mercurial or in the
 Python search path, create an entry for it in your configuration file,
 like this::
@@ -23,6 +15,16 @@ 
   [extensions]
   myfeature = ~/.hgext/myfeature.py
 
+See :hg:`help config` for more information on configuration files.
+
+Extensions are not loaded by default for a variety of reasons:
+they can increase startup overhead; they may be meant for advanced
+usage only; they may provide potentially dangerous abilities (such
+as letting you destroy or modify history); they might not be ready
+for prime time; or they may alter some usual behaviors of stock
+Mercurial. It is thus up to the user to activate extensions as
+needed.
+
 To explicitly disable an extension enabled in a configuration file of
 broader scope, prepend its path with !::