launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #04078
[Merge] lp:~matthew.revell/launchpad/inline-recipe-editor-help-721065 into lp:launchpad
Matthew Revell has proposed merging lp:~matthew.revell/launchpad/inline-recipe-editor-help-721065 into lp:launchpad.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
Related bugs:
Bug #721065 in Launchpad itself: "No documentation for inline recipe text editor"
https://bugs.launchpad.net/launchpad/+bug/721065
For more details, see:
https://code.launchpad.net/~matthew.revell/launchpad/inline-recipe-editor-help-721065/+merge/66158
This removes the pop-up help from the edit recipe page and replaces it with a link to the help wiki. This is to avoid having to maintain two separate versions of effectively the same document.
I favoured the help wiki version because:
* it's available to people who aren't in the recipe UI at that time
* it's better suited to someone who wants a reference while writing a recipe.
This branch also adds a link to that help page beneath the in-line recipe editor. We (Gavin, Huw, m'self) looked at different ways of putting this on the page but a simple text link beneath the edit widget turned out to be the best compromise between getting the help link there and not spending hours and hours on what should be a trivial text fix.
--
https://code.launchpad.net/~matthew.revell/launchpad/inline-recipe-editor-help-721065/+merge/66158
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~matthew.revell/launchpad/inline-recipe-editor-help-721065 into lp:launchpad.
=== modified file 'lib/lp/code/browser/sourcepackagerecipe.py'
--- lib/lp/code/browser/sourcepackagerecipe.py 2011-05-27 21:12:25 +0000
+++ lib/lp/code/browser/sourcepackagerecipe.py 2011-06-28 14:37:28 +0000
@@ -556,12 +556,9 @@
recipe_text = has_structured_doc(
Text(
title=u'Recipe text', required=True,
- description=u"""The text of the recipe.
- <a href="/+help/recipe-syntax.html" target="help"
- >Syntax help
- <span class="sprite maybe">
- <span class="invisible-link">Help</span>
- </span></a>
+ description=u"""Enter your recipe here.
+ <a href="https://help.launchpad.net/Packaging/SourceBuilds/Recipes"
+ target="_blank">(Get help with recipe syntax)</a>
"""))
=== removed file 'lib/lp/code/help/recipe-syntax.html'
--- lib/lp/code/help/recipe-syntax.html 2010-11-26 02:02:03 +0000
+++ lib/lp/code/help/recipe-syntax.html 1970-01-01 00:00:00 +0000
@@ -1,91 +0,0 @@
-<html>
- <head>
- <title>Source package recipe syntax</title>
- <link rel="stylesheet" type="text/css"
- href="/+icing/yui/cssreset/reset.css" />
- <link rel="stylesheet" type="text/css"
- href="/+icing/yui/cssfonts/fonts.css" />
- <link rel="stylesheet" type="text/css"
- href="/+icing/yui/cssbase/base.css" />
- </head>
- <body>
- <h1>Source package recipe syntax</h1>
-
- <p>A recipe is just text that starts with a line such as:</p>
- <dl>
- <dd>
- <tt># bzr-builder format 0.2 deb-version {debupstream}-0~{revno}</tt>
- </dd>
- </dl>
-
- <p>
- The format specifier is there to allow the syntax to be changed in later
- versions, and the meaning of "deb-version" will be explained below.
- </p>
-
- <p>
- The next line specifies the base branch, this is the branch that will
- be used to define the initial files and directory structure.
- </p>
-
- <p>
- Next comes any number of lines of other branches to be merged in, but
- using a slightly different format. To merge a branch in to the base
- specify something like:
- </p>
-
- <dl>
- <dd>
- <tt>merge packaging lp:~foo-dev/foo/packaging</tt>
- </dd>
- </dl>
-
- <p>
- which specifies we are merging a branch we will refer to as "packaging",
- which can be found at the given URI. The name you give to the branch as
- the second item doesn't have to match anything else, it's just an
- identifier specific to the recipe.
- </p>
-
- <p>
- <a href="https://help.launchpad.net/Packaging/SourceBuilds/Recipes"
- target="_blank">Read more ></a> on recipe syntax for other commands and
- specifying revisions for the branches.
- </p>
-
- <h2>deb-version</h2>
-
- <p>
- To build Debian source package that you desire you should make sure that
- "deb-version" is set to an appropriate value on the first line of your
- recipe. This will be used as the version number of the package. The
- value you put there also allows for substitution of values in to it
- based on various things when the recipe is processed:
- </p>
-
- <ul class="bulleted">
- <li><tt>{date}</tt> — will be substituted with just the current
- date, such as <tt>20090819</tt></li>
- <li><tt>{debupstream}</tt> — will be replaced by the upstream
- portion of the version number taken from debian/changelog in the final
- tree. If when the tree is built the top of debian/changelog has a
- version number of "<tt>1.0-1</tt>" then this would evaluate to
- "<tt>1.0</tt>".
- </li>
- <li><tt>{revno}</tt> — will be the revno of the base branch (the
- first specified)</li>
- <li><tt>{revno:<branch name>}</tt> — will be substituted
- with the revno for the branch named <branch name> in the
- recipe</li>
- <li><tt>{time}</tt> — will be substituted with the current date
- and time, such as <tt>200908191512</tt></li>
- </ul>
-
- <p>
- <a href="https://help.launchpad.net/Packaging/SourceBuilds/Recipes"
- target="_blank">Read more ></a> on recipe syntax for other commands and
- specifying revisions for the branches.
- </p>
-
- </body>
-</html>
=== modified file 'lib/lp/code/templates/sourcepackagerecipe-index.pt'
--- lib/lp/code/templates/sourcepackagerecipe-index.pt 2011-03-31 02:29:28 +0000
+++ lib/lp/code/templates/sourcepackagerecipe-index.pt 2011-06-28 14:37:28 +0000
@@ -141,6 +141,10 @@
<div class='portlet'>
<h2>Recipe contents</h2>
<tal:widget replace="structure view/recipe_text_widget"/>
+ <p>
+ <a href="https://help.launchpad.net/Packaging/SourceBuilds/Recipes">Read
+ about recipe syntax</a>
+ </p>
</div>
<script type="text/javascript">
Follow ups